Documentation ¶
Index ¶
- func Get(client newclient.Client, spacesQuery SpacesQuery) (*resources.Resources[*Space], error)
- func IsNil(i interface{}) bool
- type Space
- type SpaceHomeQuery
- type SpaceService
- func (s *SpaceService) Add(space *Space) (*Space, error)
- func (s *SpaceService) Get(spacesQuery SpacesQuery) (*resources.Resources[*Space], error)deprecated
- func (s *SpaceService) GetAll() ([]*Space, error)deprecated
- func (s *SpaceService) GetByID(id string) (*Space, error)deprecated
- func (s *SpaceService) GetByIDOrName(idOrName string) (*Space, error)
- func (s *SpaceService) GetByName(name string) (*Space, error)
- func (s *SpaceService) Update(space *Space) (*Space, error)deprecated
- type SpacesQuery
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Space ¶
type Space struct { Description string `json:"Description,omitempty"` Slug string `json:"Slug"` // deliberately send empty string IsDefault bool `json:"IsDefault"` Name string `json:"Name" validate:"required,max=20"` SpaceManagersTeamMembers []string `json:"SpaceManagersTeamMembers"` // deliberately send empty array SpaceManagersTeams []string `json:"SpaceManagersTeams"` // deliberately send empty array TaskQueueStopped bool `json:"TaskQueueStopped"` resources.Resource }
func GetAll ¶ added in v2.33.0
GetAll returns all spaces. If none can be found or an error occurs, it returns an empty collection.
func GetByID ¶ added in v2.33.0
GetByID returns the space that matches the input ID. If one cannot be found, it returns nil and an error.
func GetDefaultSpace ¶ added in v2.33.0
GetDefaultSpace tries to find default space. Returns nil if a default space can not be found.
type SpaceHomeQuery ¶
type SpaceHomeQuery struct {
SpaceID string `uri:"spaceId,omitempty" url:"spaceId,omitempty"`
}
type SpaceService ¶
type SpaceService struct { services.CanDeleteService // contains filtered or unexported fields }
func NewSpaceService ¶
func NewSpaceService(sling *sling.Sling, uriTemplate string, homePath string) *SpaceService
func (*SpaceService) Add ¶
func (s *SpaceService) Add(space *Space) (*Space, error)
Add creates a new space.
func (*SpaceService) Get
deprecated
func (s *SpaceService) Get(spacesQuery SpacesQuery) (*resources.Resources[*Space], error)
Get returns a collection of spaces 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 spaces.Get
func (*SpaceService) GetAll
deprecated
func (s *SpaceService) GetAll() ([]*Space, error)
GetAll returns all spaces. If none can be found or an error occurs, it returns an empty collection.
Deprecated: Use spaces.GetAll
func (*SpaceService) GetByID
deprecated
func (s *SpaceService) GetByID(id string) (*Space, error)
GetByID returns the space that matches the input ID. If one cannot be found, it returns nil and an error.
Deprecated: Use spaces.GetByID
func (*SpaceService) GetByIDOrName ¶
func (s *SpaceService) GetByIDOrName(idOrName string) (*Space, error)
GetByIDOrName returns the space that matches the input ID or name. If one cannot be found, it returns nil and an error.
func (*SpaceService) GetByName ¶
func (s *SpaceService) GetByName(name string) (*Space, error)
GetByName returns the space that matches the input ID or name. If one cannot be found, it returns nil and an error.
func (*SpaceService) Update
deprecated
func (s *SpaceService) Update(space *Space) (*Space, error)
Update modifies a space based on the one provided as input.
Deprecated: Use spaces.Update