Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CardinalHandler ¶
type CardinalHandler interface {
Start(ctx context.Context, f models.StartCardinalFlags) error
Stop(ctx context.Context, f models.StopCardinalFlags) error
Restart(ctx context.Context, f models.RestartCardinalFlags) error
Dev(ctx context.Context, f models.DevCardinalFlags) error
Purge(ctx context.Context, f models.PurgeCardinalFlags) error
Build(ctx context.Context, f models.BuildCardinalFlags) error
}
type CloudHandler ¶
type CloudHandler interface {
// Deployment handles project deployment operations (deploy, destroy, reset, promote).
Deployment(ctx context.Context, organizationID string, project models.Project, deployType string) error
// Status displays the current deployment status for a project.
Status(ctx context.Context, organization models.Organization, project models.Project) error
// TailLogs streams logs from a specific deployment environment.
TailLogs(ctx context.Context, region string, env string) error
}
CloudHandler defines the interface for cloud deployment and management operations.
type CommandSetupController ¶
type CommandSetupController interface {
// SetupCommandState performs the setup flow for commands and returns the established state.
// Handles login, organization, and project setup based on requirements.
SetupCommandState(ctx context.Context, req models.SetupRequest) (models.CommandState, error)
}
CommandSetupController defines the interface for command setup operations.
type EVMHandler ¶
type EVMHandler interface {
Start(ctx context.Context, flags models.StartEVMFlags) error
Stop(ctx context.Context, flags models.StopEVMFlags) error
}
type OrganizationHandler ¶
type OrganizationHandler interface {
// Create creates a new organization with the specified details.
Create(
ctx context.Context,
flags models.CreateOrganizationFlags,
) (models.Organization, error)
// Switch handles organization selection and switching logic.
Switch(
ctx context.Context,
flags models.SwitchOrganizationFlags,
) (models.Organization, error)
// MembersList lists members of an organization.
MembersList(
ctx context.Context,
org models.Organization,
flags models.MembersListFlags,
) error
// PromptForSwitch manages organization selection with optional creation.
// If enableCreation is true, allows creating a new organization during selection.
PromptForSwitch(
ctx context.Context,
orgs []models.Organization,
enableCreation bool,
) (models.Organization, error)
// PrintNoOrganizations displays guidance when no organizations exist.
PrintNoOrganizations()
}
OrganizationHandler defines the interface for organization-related operations.
type ProjectHandler ¶
type ProjectHandler interface {
// Create creates a new project in the specified organization.
Create(ctx context.Context, org models.Organization, flags models.CreateProjectFlags) (models.Project, error)
// Switch handles project selection and switching logic.
// If enableCreation is true, allows creating a new project during switch.
Switch(
ctx context.Context,
flags models.SwitchProjectFlags,
org models.Organization,
enableCreation bool,
) (models.Project, error)
// HandleSwitch performs the actual project switching operation.
HandleSwitch(ctx context.Context, org models.Organization) error
// Update modifies an existing project with new information.
Update(ctx context.Context, project models.Project, org models.Organization, flags models.UpdateProjectFlags) error
// Delete removes a project from the organization.
Delete(ctx context.Context, project models.Project) error
// PreCreateUpdateValidation validates the current environment for project operations.
// Returns repository path, URL, and any validation errors.
PreCreateUpdateValidation(printError bool) (string, string, error)
// PrintNoProjectsInOrganization displays guidance when no projects exist.
PrintNoProjectsInOrganization()
}
ProjectHandler defines the interface for project-related operations.
type RootHandler ¶
type RootHandler interface {
// Create initializes a new World project in the specified directory.
Create(directory string) error
// Doctor performs system diagnostics and validation checks.
Doctor() error
// Version displays version information and optionally checks for updates.
Version(check bool) error
// Login handles user authentication and login flow.
Login(ctx context.Context) error
// SetAppVersion sets the application version for display purposes.
SetAppVersion(version string)
}
RootHandler defines the interface for root-level CLI operations.
type UserHandler ¶
type UserHandler interface {
// InviteToOrganization invites a user to join an organization with a specific role.
InviteToOrganization(
ctx context.Context,
organization models.Organization,
flags models.InviteUserToOrganizationFlags,
) error
// ChangeRoleInOrganization updates a user's role within an organization.
ChangeRoleInOrganization(
ctx context.Context,
organization models.Organization,
flags models.ChangeUserRoleInOrganizationFlags,
) error
// Update modifies the current user's profile information.
Update(ctx context.Context, flags models.UpdateUserFlags) error
}
UserHandler defines the interface for user-related operations.
Click to show internal directories.
Click to hide internal directories.