Documentation ¶
Index ¶
- func IsNil(i interface{}) bool
- type Environment
- type EnvironmentService
- func (s *EnvironmentService) Add(environment *Environment) (*Environment, error)
- func (s *EnvironmentService) Get(environmentsQuery EnvironmentsQuery) (*resources.Resources[*Environment], error)
- func (s *EnvironmentService) GetAll() ([]*Environment, error)
- func (s *EnvironmentService) GetByID(id string) (*Environment, error)
- func (s *EnvironmentService) GetByIDs(ids []string) ([]*Environment, error)
- func (s *EnvironmentService) GetByName(name string) ([]*Environment, error)
- func (s *EnvironmentService) GetByPartialName(partialName string) ([]*Environment, error)
- func (s *EnvironmentService) Update(environment *Environment) (*Environment, error)
- type EnvironmentsQuery
- type EnvironmentsSummaryQuery
- type JiraExtensionSettings
- type JiraServiceManagementExtensionSettings
- func (j *JiraServiceManagementExtensionSettings) ExtensionID() extensions.ExtensionID
- func (j *JiraServiceManagementExtensionSettings) IsChangeControlled() bool
- func (j JiraServiceManagementExtensionSettings) MarshalJSON() ([]byte, error)
- func (j *JiraServiceManagementExtensionSettings) SetExtensionID(extensionID extensions.ExtensionID)
- func (j *JiraServiceManagementExtensionSettings) SetIsChangeControlled(isChangeControlled bool)
- func (j *JiraServiceManagementExtensionSettings) UnmarshalJSON(b []byte) error
- type ServiceNowExtensionSettings
- func (s *ServiceNowExtensionSettings) ExtensionID() extensions.ExtensionID
- func (s *ServiceNowExtensionSettings) IsChangeControlled() bool
- func (s ServiceNowExtensionSettings) MarshalJSON() ([]byte, error)
- func (s *ServiceNowExtensionSettings) SetExtensionID(extensionID extensions.ExtensionID)
- func (s *ServiceNowExtensionSettings) SetIsChangeControlled(isChangeControlled bool)
- func (s *ServiceNowExtensionSettings) UnmarshalJSON(b []byte) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Environment ¶
type Environment struct { AllowDynamicInfrastructure bool `json:"AllowDynamicInfrastructure"` Description string `json:"Description,omitempty"` ExtensionSettings []extensions.ExtensionSettings `json:"ExtensionSettings,omitempty"` Name string `json:"Name" validate:"required"` Slug string `json:"Slug"` // deliberately send empty string SortOrder int `json:"SortOrder"` SpaceID string `json:"SpaceId"` UseGuidedFailure bool `json:"UseGuidedFailure"` resources.Resource }
func NewEnvironment ¶
func NewEnvironment(name string) *Environment
func (*Environment) GetName ¶ added in v2.2.0
func (e *Environment) GetName() string
GetName returns the name of the environment.
func (*Environment) SetName ¶ added in v2.3.0
func (e *Environment) SetName(name string)
SetName sets the name of the environment.
func (*Environment) UnmarshalJSON ¶ added in v2.17.3
func (e *Environment) UnmarshalJSON(data []byte) error
UnmarshalJSON sets an environment to its representation in JSON.
func (*Environment) Validate ¶
func (e *Environment) Validate() error
Validate checks the state of the environment and returns an error if invalid.
type EnvironmentService ¶
type EnvironmentService struct { services.CanDeleteService // contains filtered or unexported fields }
func NewEnvironmentService ¶
func NewEnvironmentService(sling *sling.Sling, uriTemplate string, sortOrderPath string, summaryPath string) *EnvironmentService
NewEnvironmentService returns an EnvironmentService with a preconfigured client.
func (*EnvironmentService) Add ¶
func (s *EnvironmentService) Add(environment *Environment) (*Environment, error)
Add creates a new environment.
func (*EnvironmentService) Get ¶
func (s *EnvironmentService) Get(environmentsQuery EnvironmentsQuery) (*resources.Resources[*Environment], error)
Get returns a collection of environments based on the criteria defined by its input query parameter. If an error occurs, an empty collection is returned along with the associated error.
func (*EnvironmentService) GetAll ¶
func (s *EnvironmentService) GetAll() ([]*Environment, error)
GetAll returns all environments. If none can be found or an error occurs, it returns an empty collection.
func (*EnvironmentService) GetByID ¶
func (s *EnvironmentService) GetByID(id string) (*Environment, error)
GetByID returns the environment that matches the input ID. If one cannot be found, it returns nil and an error.
func (*EnvironmentService) GetByIDs ¶
func (s *EnvironmentService) GetByIDs(ids []string) ([]*Environment, error)
GetByIDs returns the environments that match the input IDs.
func (*EnvironmentService) GetByName ¶
func (s *EnvironmentService) GetByName(name string) ([]*Environment, error)
GetByName returns the environments with a matching partial name.
func (*EnvironmentService) GetByPartialName ¶
func (s *EnvironmentService) GetByPartialName(partialName string) ([]*Environment, error)
GetByPartialName performs a lookup and returns enironments with a matching partial name.
func (*EnvironmentService) Update ¶
func (s *EnvironmentService) Update(environment *Environment) (*Environment, error)
Update modifies an environment based on the one provided as input.
type EnvironmentsQuery ¶
type EnvironmentsQuery struct { IDs []string `uri:"ids,omitempty" url:"ids,omitempty"` Name string `uri:"name,omitempty" url:"name,omitempty"` PartialName string `uri:"partialName,omitempty" url:"partialName,omitempty"` Skip int `uri:"skip,omitempty" url:"skip,omitempty"` Take int `uri:"take,omitempty" url:"take,omitempty"` }
type EnvironmentsSummaryQuery ¶
type EnvironmentsSummaryQuery struct { CommunicationStyles []string `uri:"commStyles,omitempty" url:"commStyles,omitempty"` HealthStatuses []string `uri:"healthStatuses,omitempty" url:"healthStatuses,omitempty"` HideEmptyEnvironments bool `uri:"hideEmptyEnvironments,omitempty" url:"hideEmptyEnvironments,omitempty"` IDs []string `uri:"ids,omitempty" url:"ids,omitempty"` IsDisabled bool `uri:"isDisabled,omitempty" url:"isDisabled,omitempty"` MachinePartialName string `uri:"machinePartialName,omitempty" url:"machinePartialName,omitempty"` PartialName string `uri:"partialName,omitempty" url:"partialName,omitempty"` Roles []string `uri:"roles,omitempty" url:"roles,omitempty"` ShellNames []string `uri:"shellNames,omitempty" url:"shellNames,omitempty"` TenantIDs []string `uri:"tenantIds,omitempty" url:"tenantIds,omitempty"` TenantTags []string `uri:"tenantTags,omitempty" url:"tenantTags,omitempty"` }
type JiraExtensionSettings ¶ added in v2.17.3
type JiraExtensionSettings struct { JiraEnvironmentType string ext.ExtensionSettings }
func NewJiraExtensionSettings ¶ added in v2.17.3
func NewJiraExtensionSettings(environmentType string) *JiraExtensionSettings
NewJiraExtensionSettings creates an instance of extension settings for Jira.
func (*JiraExtensionSettings) ExtensionID ¶ added in v2.17.3
func (j *JiraExtensionSettings) ExtensionID() extensions.ExtensionID
func (JiraExtensionSettings) MarshalJSON ¶ added in v2.17.3
func (j JiraExtensionSettings) MarshalJSON() ([]byte, error)
MarshalJSON returns the Jira extension settings as its JSON encoding.
func (*JiraExtensionSettings) SetExtensionID ¶ added in v2.17.3
func (j *JiraExtensionSettings) SetExtensionID(extensionID extensions.ExtensionID)
func (*JiraExtensionSettings) UnmarshalJSON ¶ added in v2.17.3
func (j *JiraExtensionSettings) UnmarshalJSON(b []byte) error
UnmarshalJSON sets the Jira extension settings to its representation in JSON.
type JiraServiceManagementExtensionSettings ¶ added in v2.17.3
type JiraServiceManagementExtensionSettings struct {
ext.ChangeControlExtensionSettings
}
func NewJiraServiceManagementExtensionSettings ¶ added in v2.17.3
func NewJiraServiceManagementExtensionSettings(isChangeControlled bool) *JiraServiceManagementExtensionSettings
NewJiraServiceManagementExtensionSettings creates an instance of extension settings for Jira Service Management (JSM).
func (*JiraServiceManagementExtensionSettings) ExtensionID ¶ added in v2.17.3
func (j *JiraServiceManagementExtensionSettings) ExtensionID() extensions.ExtensionID
func (*JiraServiceManagementExtensionSettings) IsChangeControlled ¶ added in v2.17.3
func (j *JiraServiceManagementExtensionSettings) IsChangeControlled() bool
func (JiraServiceManagementExtensionSettings) MarshalJSON ¶ added in v2.17.3
func (j JiraServiceManagementExtensionSettings) MarshalJSON() ([]byte, error)
MarshalJSON returns the Jira Service Management (JSM) extension settings as its JSON encoding.
func (*JiraServiceManagementExtensionSettings) SetExtensionID ¶ added in v2.17.3
func (j *JiraServiceManagementExtensionSettings) SetExtensionID(extensionID extensions.ExtensionID)
func (*JiraServiceManagementExtensionSettings) SetIsChangeControlled ¶ added in v2.17.3
func (j *JiraServiceManagementExtensionSettings) SetIsChangeControlled(isChangeControlled bool)
func (*JiraServiceManagementExtensionSettings) UnmarshalJSON ¶ added in v2.17.3
func (j *JiraServiceManagementExtensionSettings) UnmarshalJSON(b []byte) error
UnmarshalJSON sets the Jira Service Management (JSM) extension settings to its representation in JSON.
type ServiceNowExtensionSettings ¶ added in v2.17.3
type ServiceNowExtensionSettings struct {
ext.ChangeControlExtensionSettings
}
func NewServiceNowExtensionSettings ¶ added in v2.17.3
func NewServiceNowExtensionSettings(isChangeControlled bool) *ServiceNowExtensionSettings
NewServiceNowExtensionSettings creates an instance of extension settings for ServiceNow.
func (*ServiceNowExtensionSettings) ExtensionID ¶ added in v2.17.3
func (s *ServiceNowExtensionSettings) ExtensionID() extensions.ExtensionID
func (*ServiceNowExtensionSettings) IsChangeControlled ¶ added in v2.17.3
func (s *ServiceNowExtensionSettings) IsChangeControlled() bool
func (ServiceNowExtensionSettings) MarshalJSON ¶ added in v2.17.3
func (s ServiceNowExtensionSettings) MarshalJSON() ([]byte, error)
MarshalJSON returns the ServiceNow extension settings as its JSON encoding.
func (*ServiceNowExtensionSettings) SetExtensionID ¶ added in v2.17.3
func (s *ServiceNowExtensionSettings) SetExtensionID(extensionID extensions.ExtensionID)
func (*ServiceNowExtensionSettings) SetIsChangeControlled ¶ added in v2.17.3
func (s *ServiceNowExtensionSettings) SetIsChangeControlled(isChangeControlled bool)
func (*ServiceNowExtensionSettings) UnmarshalJSON ¶ added in v2.17.3
func (s *ServiceNowExtensionSettings) UnmarshalJSON(b []byte) error
UnmarshalJSON sets the ServiceNow extension settings to its representation in JSON.