projectgroups

package
v2.36.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 15, 2023 License: Apache-2.0 Imports: 11 Imported by: 8

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeleteByID added in v2.33.0

func DeleteByID(client newclient.Client, spaceID string, id string) error

DeleteByID deletes the resource that matches the space ID and input ID.

func Get added in v2.33.0

func Get(client newclient.Client, spaceID string, projectGroupsQuery ProjectGroupsQuery) (*resources.Resources[*ProjectGroup], error)

Get returns a collection of project groups 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 IsNil

func IsNil(i interface{}) bool

Types

type ProjectGroup

type ProjectGroup struct {
	Description       string   `json:"Description,omitempty"`
	EnvironmentIDs    []string `json:"EnvironmentIds,omitempty"`
	Name              string   `json:"Name,omitempty" validate:"required"`
	RetentionPolicyID string   `json:"RetentionPolicyId,omitempty"`
	SpaceID           string   `json:"SpaceId,omitempty"`

	resources.Resource
}

func Add added in v2.33.0

func Add(client newclient.Client, projectGroup *ProjectGroup) (*ProjectGroup, error)

Add creates a new project group.

func GetAll added in v2.34.0

func GetAll(client newclient.Client, spaceID string) ([]*ProjectGroup, error)

GetAll returns all project groups. If an error occurs, it returns nil.

func GetByID added in v2.33.0

func GetByID(client newclient.Client, spaceID string, id string) (*ProjectGroup, error)

GetByID returns the project group that matches the input ID. If one cannot be found, it returns nil and an error.

func NewProjectGroup

func NewProjectGroup(name string) *ProjectGroup

func Update added in v2.33.0

func Update(client newclient.Client, resource ProjectGroup) (*ProjectGroup, error)

Update modifies a project group based on the one provided as input.

func (*ProjectGroup) GetName added in v2.11.1

func (s *ProjectGroup) GetName() string

type ProjectGroupService

type ProjectGroupService struct {
	services.CanDeleteService
}

ProjectGroupService handles communication with ProjectGroup-related methods of the Octopus API.

func NewProjectGroupService

func NewProjectGroupService(sling *sling.Sling, uriTemplate string) *ProjectGroupService

NewProjectGroupService returns a projectGroupService with a preconfigured client.

func (*ProjectGroupService) Add deprecated

func (s *ProjectGroupService) Add(projectGroup *ProjectGroup) (*ProjectGroup, error)

Add creates a new project group.

Deprecated: Use projectgroups.Add

func (*ProjectGroupService) Get deprecated

Get returns a collection of project groups based on the criteria defined by its input query parameter. If an error occurs, an empty collection is returned along with the associated error.

Deprecated: Use projectgroups.Get

func (*ProjectGroupService) GetAll

func (s *ProjectGroupService) GetAll() ([]*ProjectGroup, error)

GetAll returns all project groups. If none can be found or an error occurs, it returns an empty collection.

Deprecates: use projectgroups.GetAll

func (*ProjectGroupService) GetByID deprecated

func (s *ProjectGroupService) GetByID(id string) (*ProjectGroup, error)

GetByID returns the project group that matches the input ID. If one cannot be found, it returns nil and an error.

Deprecated: Use projectgroups.GetByID

func (*ProjectGroupService) GetByIDOrName added in v2.8.0

func (s *ProjectGroupService) GetByIDOrName(idOrName string) (*ProjectGroup, error)

func (*ProjectGroupService) GetByName added in v2.8.0

func (s *ProjectGroupService) GetByName(name string) (*ProjectGroup, error)

func (*ProjectGroupService) GetByPartialName

func (s *ProjectGroupService) GetByPartialName(partialName string) ([]*ProjectGroup, error)

GetByPartialName performs a lookup and returns a collection of project groups with a matching partial name.

func (*ProjectGroupService) GetProjects

func (s *ProjectGroupService) GetProjects(projectGroup *ProjectGroup) ([]*projects.Project, error)

func (*ProjectGroupService) Update deprecated

func (s *ProjectGroupService) Update(resource ProjectGroup) (*ProjectGroup, error)

Update modifies a project group based on the one provided as input.

Deprecated: Use projectgroups.Update

type ProjectGroupsQuery

type ProjectGroupsQuery struct {
	IDs         []string `uri:"ids,omitempty" url:"ids,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"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL