api

package
Version: v6.0.1234+incompatible Latest Latest
Warning

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

Go to latest
Published: Mar 5, 2014 License: Apache-2.0 Imports: 34 Imported by: 0

Documentation

Index

Constants

View Source
const APP_EVENT_TIMESTAMP_FORMAT = "2006-01-02T15:04:05-07:00"
View Source
const LogBufferSize = 1024
View Source
const MAX_INT64 int64 = 1<<63 - 1

Variables

View Source
var KNOWN_METADATA_KEYS = []string{
	"index",
	"reason",
	"exit_description",
	"exit_status",
	"recursive",
	"disk_quota",
	"instances",
	"memory",
	"state",
	"command",
	"environment_json",
}

Functions

This section is empty.

Types

type AppEventsRepository

type AppEventsRepository interface {
	ListEvents(appGuid string, cb func(models.EventFields) bool) errors.Error
}

type AppFileResource

type AppFileResource struct {
	Path string `json:"fn"`
	Sha1 string `json:"sha1"`
	Size int64  `json:"size"`
}

type AppFilesRepository

type AppFilesRepository interface {
	ListFiles(appGuid, path string) (files string, apiErr errors.Error)
}

type AppInstancesRepository

type AppInstancesRepository interface {
	GetInstances(appGuid string) (instances []models.AppInstanceFields, apiErr errors.Error)
}

type AppRouteEntity

type AppRouteEntity struct {
	Host   string
	Domain Resource
}

type AppRouteResource

type AppRouteResource struct {
	Resource
	Entity AppRouteEntity
}

func (AppRouteResource) ToFields

func (resource AppRouteResource) ToFields() (route models.RouteFields)

func (AppRouteResource) ToModel

func (resource AppRouteResource) ToModel() (route models.RouteSummary)

type AppSummaryRepository

type AppSummaryRepository interface {
	GetSummariesInCurrentSpace() (apps []models.AppSummary, apiErr errors.Error)
	GetSummary(appGuid string) (summary models.AppSummary, apiErr errors.Error)
}

type ApplicationBitsRepository

type ApplicationBitsRepository interface {
	UploadApp(appGuid, dir string, cb func(path string, zipSize, fileCount uint64)) (apiErr errors.Error)
}

type ApplicationEntity

type ApplicationEntity struct {
	Name               *string             `json:"name,omitempty"`
	Command            *string             `json:"command,omitempty"`
	State              *string             `json:"state,omitempty"`
	SpaceGuid          *string             `json:"space_guid,omitempty"`
	Instances          *int                `json:"instances,omitempty"`
	Memory             *uint64             `json:"memory,omitempty"`
	DiskQuota          *uint64             `json:"disk_quota,omitempty"`
	StackGuid          *string             `json:"stack_guid,omitempty"`
	Stack              *StackResource      `json:"stack,omitempty"`
	Routes             *[]AppRouteResource `json:"routes,omitempty"`
	Buildpack          *string             `json:"buildpack,omitempty"`
	EnvironmentJson    *map[string]string  `json:"environment_json,omitempty"`
	HealthCheckTimeout *int                `json:"health_check_timeout,omitempty"`
}

func NewApplicationEntityFromAppParams

func NewApplicationEntityFromAppParams(app models.AppParams) ApplicationEntity

type ApplicationFromSummary

type ApplicationFromSummary struct {
	Guid             string
	Name             string
	Routes           []RouteSummary
	RunningInstances int `json:"running_instances"`
	Memory           uint64
	Instances        int
	DiskQuota        uint64 `json:"disk_quota"`
	Urls             []string
	State            string
	SpaceGuid        string `json:"space_guid"`
}

func (ApplicationFromSummary) ToFields

func (resource ApplicationFromSummary) ToFields() (app models.ApplicationFields)

func (ApplicationFromSummary) ToModel

func (resource ApplicationFromSummary) ToModel() (app models.AppSummary)

type ApplicationRepository

type ApplicationRepository interface {
	Create(params models.AppParams) (createdApp models.Application, apiErr errors.Error)
	Read(name string) (app models.Application, apiErr errors.Error)
	Update(appGuid string, params models.AppParams) (updatedApp models.Application, apiErr errors.Error)
	Delete(appGuid string) (apiErr errors.Error)
}

type ApplicationResource

type ApplicationResource struct {
	Resource
	Entity ApplicationEntity
}

func (ApplicationResource) ToFields

func (resource ApplicationResource) ToFields() (app models.ApplicationFields)

func (ApplicationResource) ToModel

func (resource ApplicationResource) ToModel() (app models.Application)

type ApplicationSummaries

type ApplicationSummaries struct {
	Apps []ApplicationFromSummary
}

func (ApplicationSummaries) ToModels

func (resource ApplicationSummaries) ToModels() (apps []models.ApplicationFields)

type AuthTokenEntity

type AuthTokenEntity struct {
	Label    string
	Provider string
}

type AuthTokenResource

type AuthTokenResource struct {
	Resource
	Entity AuthTokenEntity
}

type AuthenticationRepository

type AuthenticationRepository interface {
	Authenticate(credentials map[string]string) (apiErr errors.Error)
	RefreshAuthToken() (updatedToken string, apiErr errors.Error)
	GetLoginPrompts() (map[string]configuration.AuthPrompt, errors.Error)
}

type BuildpackBitsRepository

type BuildpackBitsRepository interface {
	UploadBuildpack(buildpack models.Buildpack, dir string) (apiErr errors.Error)
}

type BuildpackEntity

type BuildpackEntity struct {
	Name     string `json:"name"`
	Position *int   `json:"position,omitempty"`
	Enabled  *bool  `json:"enabled,omitempty"`
	Key      string `json:"key,omitempty"`
	Filename string `json:"filename,omitempty"`
	Locked   *bool  `json:"locked,omitempty"`
}

type BuildpackRepository

type BuildpackRepository interface {
	FindByName(name string) (buildpack models.Buildpack, apiErr errors.Error)
	ListBuildpacks(func(models.Buildpack) bool) errors.Error
	Create(name string, position *int, enabled *bool, locked *bool) (createdBuildpack models.Buildpack, apiErr errors.Error)
	Delete(buildpackGuid string) (apiErr errors.Error)
	Update(buildpack models.Buildpack) (updatedBuildpack models.Buildpack, apiErr errors.Error)
}

type BuildpackResource

type BuildpackResource struct {
	Metadata Metadata
	Entity   BuildpackEntity
}

func (BuildpackResource) ToFields

func (resource BuildpackResource) ToFields() models.Buildpack

type CCUserProvidedServiceInstanceRepository

type CCUserProvidedServiceInstanceRepository struct {
	// contains filtered or unexported fields
}

func NewCCUserProvidedServiceInstanceRepository

func NewCCUserProvidedServiceInstanceRepository(config configuration.Reader, gateway net.Gateway) (repo CCUserProvidedServiceInstanceRepository)

func (CCUserProvidedServiceInstanceRepository) Create

func (repo CCUserProvidedServiceInstanceRepository) Create(name, drainUrl string, params map[string]string) (apiErr errors.Error)

func (CCUserProvidedServiceInstanceRepository) Update

func (repo CCUserProvidedServiceInstanceRepository) Update(serviceInstanceFields models.ServiceInstanceFields) (apiErr errors.Error)

type CloudControllerAppEventsRepository

type CloudControllerAppEventsRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerAppEventsRepository

func NewCloudControllerAppEventsRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerAppEventsRepository)

func (CloudControllerAppEventsRepository) ListEvents

func (repo CloudControllerAppEventsRepository) ListEvents(appGuid string, cb func(models.EventFields) bool) errors.Error

type CloudControllerAppFilesRepository

type CloudControllerAppFilesRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerAppFilesRepository

func NewCloudControllerAppFilesRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerAppFilesRepository)

func (CloudControllerAppFilesRepository) ListFiles

func (repo CloudControllerAppFilesRepository) ListFiles(appGuid, path string) (files string, apiErr errors.Error)

type CloudControllerAppInstancesRepository

type CloudControllerAppInstancesRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerAppInstancesRepository

func NewCloudControllerAppInstancesRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerAppInstancesRepository)

func (CloudControllerAppInstancesRepository) GetInstances

func (repo CloudControllerAppInstancesRepository) GetInstances(appGuid string) (instances []models.AppInstanceFields, apiErr errors.Error)

type CloudControllerAppSummaryRepository

type CloudControllerAppSummaryRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerAppSummaryRepository

func NewCloudControllerAppSummaryRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerAppSummaryRepository)

func (CloudControllerAppSummaryRepository) GetSummariesInCurrentSpace

func (repo CloudControllerAppSummaryRepository) GetSummariesInCurrentSpace() (apps []models.AppSummary, apiErr errors.Error)

func (CloudControllerAppSummaryRepository) GetSummary

func (repo CloudControllerAppSummaryRepository) GetSummary(appGuid string) (summary models.AppSummary, apiErr errors.Error)

type CloudControllerApplicationBitsRepository

type CloudControllerApplicationBitsRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerApplicationBitsRepository

func NewCloudControllerApplicationBitsRepository(config configuration.Reader, gateway net.Gateway, zipper cf.Zipper) (repo CloudControllerApplicationBitsRepository)

func (CloudControllerApplicationBitsRepository) UploadApp

func (repo CloudControllerApplicationBitsRepository) UploadApp(appGuid string, appDir string, cb func(path string, zipSize, fileCount uint64)) (apiErr errors.Error)

type CloudControllerApplicationRepository

type CloudControllerApplicationRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerApplicationRepository

func NewCloudControllerApplicationRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerApplicationRepository)

func (CloudControllerApplicationRepository) Create

func (repo CloudControllerApplicationRepository) Create(params models.AppParams) (createdApp models.Application, apiErr errors.Error)

func (CloudControllerApplicationRepository) Delete

func (repo CloudControllerApplicationRepository) Delete(appGuid string) (apiErr errors.Error)

func (CloudControllerApplicationRepository) Read

func (CloudControllerApplicationRepository) Update

func (repo CloudControllerApplicationRepository) Update(appGuid string, params models.AppParams) (updatedApp models.Application, apiErr errors.Error)

type CloudControllerBuildpackBitsRepository

type CloudControllerBuildpackBitsRepository struct {
	TrustedCerts []tls.Certificate
	// contains filtered or unexported fields
}

func NewCloudControllerBuildpackBitsRepository

func NewCloudControllerBuildpackBitsRepository(config configuration.Reader, gateway net.Gateway, zipper cf.Zipper) (repo CloudControllerBuildpackBitsRepository)

func (CloudControllerBuildpackBitsRepository) UploadBuildpack

func (repo CloudControllerBuildpackBitsRepository) UploadBuildpack(buildpack models.Buildpack, buildpackLocation string) (apiErr errors.Error)

type CloudControllerBuildpackRepository

type CloudControllerBuildpackRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerBuildpackRepository

func NewCloudControllerBuildpackRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerBuildpackRepository)

func (CloudControllerBuildpackRepository) Create

func (repo CloudControllerBuildpackRepository) Create(name string, position *int, enabled *bool, locked *bool) (createdBuildpack models.Buildpack, apiErr errors.Error)

func (CloudControllerBuildpackRepository) Delete

func (repo CloudControllerBuildpackRepository) Delete(buildpackGuid string) (apiErr errors.Error)

func (CloudControllerBuildpackRepository) FindByName

func (repo CloudControllerBuildpackRepository) FindByName(name string) (buildpack models.Buildpack, apiErr errors.Error)

func (CloudControllerBuildpackRepository) ListBuildpacks

func (repo CloudControllerBuildpackRepository) ListBuildpacks(cb func(models.Buildpack) bool) errors.Error

func (CloudControllerBuildpackRepository) Update

func (repo CloudControllerBuildpackRepository) Update(buildpack models.Buildpack) (updatedBuildpack models.Buildpack, apiErr errors.Error)

type CloudControllerCurlRepository

type CloudControllerCurlRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerCurlRepository

func NewCloudControllerCurlRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerCurlRepository)

func (CloudControllerCurlRepository) Request

func (repo CloudControllerCurlRepository) Request(method, path, headerString, body string) (resHeaders, resBody string, apiErr errors.Error)

type CloudControllerDomainRepository

type CloudControllerDomainRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerDomainRepository

func NewCloudControllerDomainRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerDomainRepository)

func (CloudControllerDomainRepository) Create

func (repo CloudControllerDomainRepository) Create(domainName string, owningOrgGuid string) (createdDomain models.DomainFields, apiErr errors.Error)

func (CloudControllerDomainRepository) CreateSharedDomain

func (repo CloudControllerDomainRepository) CreateSharedDomain(domainName string) (apiErr errors.Error)

func (CloudControllerDomainRepository) Delete

func (repo CloudControllerDomainRepository) Delete(domainGuid string) (apiErr errors.Error)

func (CloudControllerDomainRepository) DeleteSharedDomain

func (repo CloudControllerDomainRepository) DeleteSharedDomain(domainGuid string) (apiErr errors.Error)

func (CloudControllerDomainRepository) FindByName

func (repo CloudControllerDomainRepository) FindByName(name string) (domain models.DomainFields, apiErr errors.Error)

func (CloudControllerDomainRepository) FindByNameInOrg

func (repo CloudControllerDomainRepository) FindByNameInOrg(name string, orgGuid string) (domain models.DomainFields, apiErr errors.Error)

func (CloudControllerDomainRepository) ListDomains

func (CloudControllerDomainRepository) ListDomainsForOrg

func (repo CloudControllerDomainRepository) ListDomainsForOrg(orgGuid string, cb func(models.DomainFields) bool) errors.Error

func (CloudControllerDomainRepository) ListSharedDomains

func (repo CloudControllerDomainRepository) ListSharedDomains(cb func(models.DomainFields) bool) errors.Error

type CloudControllerOrganizationRepository

type CloudControllerOrganizationRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerOrganizationRepository

func NewCloudControllerOrganizationRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerOrganizationRepository)

func (CloudControllerOrganizationRepository) Create

func (repo CloudControllerOrganizationRepository) Create(name string) (apiErr errors.Error)

func (CloudControllerOrganizationRepository) Delete

func (repo CloudControllerOrganizationRepository) Delete(orgGuid string) (apiErr errors.Error)

func (CloudControllerOrganizationRepository) FindByName

func (repo CloudControllerOrganizationRepository) FindByName(name string) (org models.Organization, apiErr errors.Error)

func (CloudControllerOrganizationRepository) ListOrgs

func (repo CloudControllerOrganizationRepository) ListOrgs(cb func(models.Organization) bool) (apiErr errors.Error)

func (CloudControllerOrganizationRepository) Rename

func (repo CloudControllerOrganizationRepository) Rename(orgGuid string, name string) (apiErr errors.Error)

type CloudControllerPasswordRepository

type CloudControllerPasswordRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerPasswordRepository

func NewCloudControllerPasswordRepository(config configuration.Reader, gateway net.Gateway, endpointRepo EndpointRepository) (repo CloudControllerPasswordRepository)

func (CloudControllerPasswordRepository) UpdatePassword

func (repo CloudControllerPasswordRepository) UpdatePassword(old string, new string) (apiErr errors.Error)

type CloudControllerQuotaRepository

type CloudControllerQuotaRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerQuotaRepository

func NewCloudControllerQuotaRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerQuotaRepository)

func (CloudControllerQuotaRepository) FindAll

func (repo CloudControllerQuotaRepository) FindAll() (quotas []models.QuotaFields, apiErr errors.Error)

func (CloudControllerQuotaRepository) FindByName

func (repo CloudControllerQuotaRepository) FindByName(name string) (quota models.QuotaFields, apiErr errors.Error)

func (CloudControllerQuotaRepository) Update

func (repo CloudControllerQuotaRepository) Update(orgGuid, quotaGuid string) (apiErr errors.Error)

type CloudControllerRouteRepository

type CloudControllerRouteRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerRouteRepository

func NewCloudControllerRouteRepository(config configuration.Reader, gateway net.Gateway, domainRepo DomainRepository) (repo CloudControllerRouteRepository)

func (CloudControllerRouteRepository) Bind

func (repo CloudControllerRouteRepository) Bind(routeGuid, appGuid string) (apiErr errors.Error)

func (CloudControllerRouteRepository) Create

func (repo CloudControllerRouteRepository) Create(host, domainGuid string) (createdRoute models.Route, apiErr errors.Error)

func (CloudControllerRouteRepository) CreateInSpace

func (repo CloudControllerRouteRepository) CreateInSpace(host, domainGuid, spaceGuid string) (createdRoute models.Route, apiErr errors.Error)

func (CloudControllerRouteRepository) Delete

func (repo CloudControllerRouteRepository) Delete(routeGuid string) (apiErr errors.Error)

func (CloudControllerRouteRepository) FindByHost

func (repo CloudControllerRouteRepository) FindByHost(host string) (route models.Route, apiErr errors.Error)

func (CloudControllerRouteRepository) FindByHostAndDomain

func (repo CloudControllerRouteRepository) FindByHostAndDomain(host, domainName string) (route models.Route, apiErr errors.Error)

func (CloudControllerRouteRepository) ListRoutes

func (repo CloudControllerRouteRepository) ListRoutes(cb func(models.Route) bool) (apiErr errors.Error)

func (CloudControllerRouteRepository) Unbind

func (repo CloudControllerRouteRepository) Unbind(routeGuid, appGuid string) (apiErr errors.Error)

type CloudControllerServiceAuthTokenRepository

type CloudControllerServiceAuthTokenRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerServiceAuthTokenRepository

func NewCloudControllerServiceAuthTokenRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerServiceAuthTokenRepository)

func (CloudControllerServiceAuthTokenRepository) Create

func (CloudControllerServiceAuthTokenRepository) Delete

func (CloudControllerServiceAuthTokenRepository) FindAll

func (CloudControllerServiceAuthTokenRepository) FindByLabelAndProvider

func (repo CloudControllerServiceAuthTokenRepository) FindByLabelAndProvider(label, provider string) (authToken models.ServiceAuthTokenFields, apiErr errors.Error)

func (CloudControllerServiceAuthTokenRepository) Update

type CloudControllerServiceBindingRepository

type CloudControllerServiceBindingRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerServiceBindingRepository

func NewCloudControllerServiceBindingRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerServiceBindingRepository)

func (CloudControllerServiceBindingRepository) Create

func (repo CloudControllerServiceBindingRepository) Create(instanceGuid, appGuid string) (apiErr errors.Error)

func (CloudControllerServiceBindingRepository) Delete

func (repo CloudControllerServiceBindingRepository) Delete(instance models.ServiceInstance, appGuid string) (found bool, apiErr errors.Error)

type CloudControllerServiceBrokerRepository

type CloudControllerServiceBrokerRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerServiceBrokerRepository

func NewCloudControllerServiceBrokerRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerServiceBrokerRepository)

func (CloudControllerServiceBrokerRepository) Create

func (repo CloudControllerServiceBrokerRepository) Create(name, url, username, password string) (apiErr errors.Error)

func (CloudControllerServiceBrokerRepository) Delete

func (repo CloudControllerServiceBrokerRepository) Delete(guid string) (apiErr errors.Error)

func (CloudControllerServiceBrokerRepository) FindByName

func (repo CloudControllerServiceBrokerRepository) FindByName(name string) (serviceBroker models.ServiceBroker, apiErr errors.Error)

func (CloudControllerServiceBrokerRepository) ListServiceBrokers

func (repo CloudControllerServiceBrokerRepository) ListServiceBrokers(callback func(models.ServiceBroker) bool) errors.Error

func (CloudControllerServiceBrokerRepository) Rename

func (repo CloudControllerServiceBrokerRepository) Rename(guid, name string) (apiErr errors.Error)

func (CloudControllerServiceBrokerRepository) Update

func (repo CloudControllerServiceBrokerRepository) Update(serviceBroker models.ServiceBroker) (apiErr errors.Error)

type CloudControllerServiceRepository

type CloudControllerServiceRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerServiceRepository

func NewCloudControllerServiceRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerServiceRepository)

func (CloudControllerServiceRepository) CreateServiceInstance

func (repo CloudControllerServiceRepository) CreateServiceInstance(name, planGuid string) (identicalAlreadyExists bool, apiErr errors.Error)

func (CloudControllerServiceRepository) DeleteService

func (repo CloudControllerServiceRepository) DeleteService(instance models.ServiceInstance) (apiErr errors.Error)

func (CloudControllerServiceRepository) FindInstanceByName

func (repo CloudControllerServiceRepository) FindInstanceByName(name string) (instance models.ServiceInstance, apiErr errors.Error)

func (CloudControllerServiceRepository) FindServiceOfferingByLabelAndProvider

func (repo CloudControllerServiceRepository) FindServiceOfferingByLabelAndProvider(label, provider string) (offering models.ServiceOffering, apiErr errors.Error)

func (CloudControllerServiceRepository) FindServicePlanByDescription

func (repo CloudControllerServiceRepository) FindServicePlanByDescription(planDescription ServicePlanDescription) (planGuid string, apiErr errors.Error)

func (CloudControllerServiceRepository) GetAllServiceOfferings

func (repo CloudControllerServiceRepository) GetAllServiceOfferings() (offerings models.ServiceOfferings, apiErr errors.Error)

func (CloudControllerServiceRepository) GetServiceInstanceCountForServicePlan

func (repo CloudControllerServiceRepository) GetServiceInstanceCountForServicePlan(v1PlanGuid string) (count int, apiErr errors.Error)

func (CloudControllerServiceRepository) GetServiceOfferingsForSpace

func (repo CloudControllerServiceRepository) GetServiceOfferingsForSpace(spaceGuid string) (offerings models.ServiceOfferings, apiErr errors.Error)

func (CloudControllerServiceRepository) MigrateServicePlanFromV1ToV2

func (repo CloudControllerServiceRepository) MigrateServicePlanFromV1ToV2(v1PlanGuid, v2PlanGuid string) (changedCount int, apiErr errors.Error)

func (CloudControllerServiceRepository) PurgeServiceOffering

func (repo CloudControllerServiceRepository) PurgeServiceOffering(offering models.ServiceOffering) errors.Error

func (CloudControllerServiceRepository) RenameService

func (repo CloudControllerServiceRepository) RenameService(instance models.ServiceInstance, newName string) (apiErr errors.Error)

type CloudControllerServiceSummaryRepository

type CloudControllerServiceSummaryRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerServiceSummaryRepository

func NewCloudControllerServiceSummaryRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerServiceSummaryRepository)

func (CloudControllerServiceSummaryRepository) GetSummariesInCurrentSpace

func (repo CloudControllerServiceSummaryRepository) GetSummariesInCurrentSpace() (instances []models.ServiceInstance, apiErr errors.Error)

type CloudControllerSpaceRepository

type CloudControllerSpaceRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerSpaceRepository

func NewCloudControllerSpaceRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerSpaceRepository)

func (CloudControllerSpaceRepository) Create

func (repo CloudControllerSpaceRepository) Create(name string, orgGuid string) (space models.Space, apiErr errors.Error)

func (CloudControllerSpaceRepository) Delete

func (repo CloudControllerSpaceRepository) Delete(spaceGuid string) (apiErr errors.Error)

func (CloudControllerSpaceRepository) FindByName

func (repo CloudControllerSpaceRepository) FindByName(name string) (space models.Space, apiErr errors.Error)

func (CloudControllerSpaceRepository) FindByNameInOrg

func (repo CloudControllerSpaceRepository) FindByNameInOrg(name, orgGuid string) (space models.Space, apiErr errors.Error)

func (CloudControllerSpaceRepository) ListSpaces

func (repo CloudControllerSpaceRepository) ListSpaces(callback func(models.Space) bool) errors.Error

func (CloudControllerSpaceRepository) Rename

func (repo CloudControllerSpaceRepository) Rename(spaceGuid, newName string) (apiErr errors.Error)

type CloudControllerStackRepository

type CloudControllerStackRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerStackRepository

func NewCloudControllerStackRepository(config configuration.Reader, gateway net.Gateway) (repo CloudControllerStackRepository)

func (CloudControllerStackRepository) FindAll

func (repo CloudControllerStackRepository) FindAll() (stacks []models.Stack, apiErr errors.Error)

func (CloudControllerStackRepository) FindByName

func (repo CloudControllerStackRepository) FindByName(name string) (stack models.Stack, apiErr errors.Error)

type CloudControllerUserRepository

type CloudControllerUserRepository struct {
	// contains filtered or unexported fields
}

func NewCloudControllerUserRepository

func NewCloudControllerUserRepository(config configuration.Reader, uaaGateway net.Gateway, ccGateway net.Gateway, endpointRepo EndpointRepository) (repo CloudControllerUserRepository)

func (CloudControllerUserRepository) Create

func (repo CloudControllerUserRepository) Create(username, password string) (apiErr errors.Error)

func (CloudControllerUserRepository) Delete

func (repo CloudControllerUserRepository) Delete(userGuid string) (apiErr errors.Error)

func (CloudControllerUserRepository) FindByUsername

func (repo CloudControllerUserRepository) FindByUsername(username string) (user models.UserFields, apiErr errors.Error)

func (CloudControllerUserRepository) ListUsersInOrgForRole

func (repo CloudControllerUserRepository) ListUsersInOrgForRole(orgGuid string, roleName string) (users []models.UserFields, apiErr errors.Error)

func (CloudControllerUserRepository) ListUsersInSpaceForRole

func (repo CloudControllerUserRepository) ListUsersInSpaceForRole(spaceGuid string, roleName string) (users []models.UserFields, apiErr errors.Error)

func (CloudControllerUserRepository) SetOrgRole

func (repo CloudControllerUserRepository) SetOrgRole(userGuid string, orgGuid string, role string) (apiErr errors.Error)

func (CloudControllerUserRepository) SetSpaceRole

func (repo CloudControllerUserRepository) SetSpaceRole(userGuid, spaceGuid, orgGuid, role string) (apiErr errors.Error)

func (CloudControllerUserRepository) UnsetOrgRole

func (repo CloudControllerUserRepository) UnsetOrgRole(userGuid, orgGuid, role string) (apiErr errors.Error)

func (CloudControllerUserRepository) UnsetSpaceRole

func (repo CloudControllerUserRepository) UnsetSpaceRole(userGuid, spaceGuid, role string) (apiErr errors.Error)

type CurlRepository

type CurlRepository interface {
	Request(method, path, header, body string) (resHeaders, resBody string, apiErr errors.Error)
}

type DomainEntity

type DomainEntity struct {
	Name                   string
	OwningOrganizationGuid string `json:"owning_organization_guid"`
}

type DomainRepository

type DomainRepository interface {
	ListDomainsForOrg(orgGuid string, cb func(models.DomainFields) bool) errors.Error
	ListSharedDomains(cb func(models.DomainFields) bool) errors.Error
	FindByName(name string) (domain models.DomainFields, apiErr errors.Error)
	FindByNameInOrg(name string, owningOrgGuid string) (domain models.DomainFields, apiErr errors.Error)
	Create(domainName string, owningOrgGuid string) (createdDomain models.DomainFields, apiErr errors.Error)
	CreateSharedDomain(domainName string) (apiErr errors.Error)
	Delete(domainGuid string) (apiErr errors.Error)
	DeleteSharedDomain(domainGuid string) (apiErr errors.Error)
	ListDomains(cb func(models.DomainFields) bool) errors.Error
}

type DomainResource

type DomainResource struct {
	Resource
	Entity DomainEntity
}

func (DomainResource) ToFields

func (resource DomainResource) ToFields() models.DomainFields

type DomainSummary

type DomainSummary struct {
	Guid                   string
	Name                   string
	OwningOrganizationGuid string
}

type EndpointRepository

type EndpointRepository interface {
	UpdateEndpoint(endpoint string) (finalEndpoint string, apiErr errors.Error)
	GetLoggregatorEndpoint() (endpoint string, apiErr errors.Error)
	GetUAAEndpoint() (endpoint string, apiErr errors.Error)
	GetCloudControllerEndpoint() (endpoint string, apiErr errors.Error)
}

type Entity

type Entity struct {
	Name string
}

type EventResourceNewV2

type EventResourceNewV2 struct {
	Resource
	Entity struct {
		Timestamp time.Time
		Type      string
		Metadata  map[string]interface{}
	}
}

func (EventResourceNewV2) ToFields

func (resource EventResourceNewV2) ToFields() models.EventFields

type EventResourceOldV2

type EventResourceOldV2 struct {
	Resource
	Entity struct {
		Timestamp       time.Time
		ExitDescription string `json:"exit_description"`
		ExitStatus      int    `json:"exit_status"`
		InstanceIndex   int    `json:"instance_index"`
	}
}

FIXME: needs semantic versioning

func (EventResourceOldV2) ToFields

func (resource EventResourceOldV2) ToFields() models.EventFields

type InstanceApiResponse

type InstanceApiResponse struct {
	State string
	Since float64
}

type InstanceStatsApiResponse

type InstanceStatsApiResponse struct {
	Stats struct {
		DiskQuota uint64 `json:"disk_quota"`
		MemQuota  uint64 `json:"mem_quota"`
		Usage     struct {
			Cpu  float64
			Disk uint64
			Mem  uint64
		}
	}
}

type InstancesApiResponse

type InstancesApiResponse map[string]InstanceApiResponse

type Item

type Item struct {
	// contains filtered or unexported fields
}

type LoggregatorLogsRepository

type LoggregatorLogsRepository struct {
	TrustedCerts []tls.Certificate
	// contains filtered or unexported fields
}

func NewLoggregatorLogsRepository

func NewLoggregatorLogsRepository(config configuration.Reader, endpointRepo EndpointRepository) LoggregatorLogsRepository

func (LoggregatorLogsRepository) RecentLogsFor

func (repo LoggregatorLogsRepository) RecentLogsFor(appGuid string, onConnect func(), logChan chan *logmessage.Message) (err error)

func (LoggregatorLogsRepository) TailLogsFor

func (repo LoggregatorLogsRepository) TailLogsFor(appGuid string, onConnect func(), logChan chan *logmessage.Message, stopLoggingChan chan bool, printTimeBuffer time.Duration) error

type LoginResource

type LoginResource struct {
	Prompts map[string][]string
}

func (*LoginResource) ToModel

func (r *LoginResource) ToModel() (prompts map[string]configuration.AuthPrompt)

type LogsRepository

type LogsRepository interface {
	RecentLogsFor(appGuid string, onConnect func(), logChan chan *logmessage.Message) (err error)
	TailLogsFor(appGuid string, onConnect func(), logChan chan *logmessage.Message, stopLoggingChan chan bool, printInterval time.Duration) (err error)
}

type Metadata

type Metadata struct {
	Guid string
	Url  string
}

type OrganizationEntity

type OrganizationEntity struct {
	Name            string
	QuotaDefinition QuotaResource `json:"quota_definition"`
	Spaces          []SpaceResource
	Domains         []DomainResource
}

type OrganizationRepository

type OrganizationRepository interface {
	ListOrgs(func(models.Organization) bool) (apiErr errors.Error)
	FindByName(name string) (org models.Organization, apiErr errors.Error)
	Create(name string) (apiErr errors.Error)
	Rename(orgGuid string, name string) (apiErr errors.Error)
	Delete(orgGuid string) (apiErr errors.Error)
}

type OrganizationResource

type OrganizationResource struct {
	Resource
	Entity OrganizationEntity
}

func (OrganizationResource) ToFields

func (resource OrganizationResource) ToFields() (fields models.OrganizationFields)

func (OrganizationResource) ToModel

func (resource OrganizationResource) ToModel() (org models.Organization)

type PaginatedApplicationResources

type PaginatedApplicationResources struct {
	Resources []ApplicationResource
}

type PaginatedAuthTokenResources

type PaginatedAuthTokenResources struct {
	Resources []AuthTokenResource
}

type PaginatedQuotaResources

type PaginatedQuotaResources struct {
	Resources []QuotaResource
}

type PaginatedServiceInstanceResources

type PaginatedServiceInstanceResources struct {
	TotalResults int `json:"total_results"`
	Resources    []ServiceInstanceResource
}

type PaginatedServiceOfferingResources

type PaginatedServiceOfferingResources struct {
	Resources []ServiceOfferingResource
}

type PaginatedStackResources

type PaginatedStackResources struct {
	Resources []StackResource
}

type PasswordRepository

type PasswordRepository interface {
	UpdatePassword(old string, new string) errors.Error
}

type QuotaEntity

type QuotaEntity struct {
	Name        string
	MemoryLimit uint64 `json:"memory_limit"`
}

type QuotaRepository

type QuotaRepository interface {
	FindAll() (quotas []models.QuotaFields, apiErr errors.Error)
	FindByName(name string) (quota models.QuotaFields, apiErr errors.Error)
	Update(orgGuid, quotaGuid string) (apiErr errors.Error)
}

type QuotaResource

type QuotaResource struct {
	Resource
	Entity QuotaEntity
}

func (QuotaResource) ToFields

func (resource QuotaResource) ToFields() (quota models.QuotaFields)

type RemoteEndpointRepository

type RemoteEndpointRepository struct {
	// contains filtered or unexported fields
}

func NewEndpointRepository

func NewEndpointRepository(config configuration.ReadWriter, gateway net.Gateway) (repo RemoteEndpointRepository)

func (RemoteEndpointRepository) GetCloudControllerEndpoint

func (repo RemoteEndpointRepository) GetCloudControllerEndpoint() (endpoint string, apiErr errors.Error)

func (RemoteEndpointRepository) GetLoggregatorEndpoint

func (repo RemoteEndpointRepository) GetLoggregatorEndpoint() (endpoint string, apiErr errors.Error)

func (RemoteEndpointRepository) GetUAAEndpoint

func (repo RemoteEndpointRepository) GetUAAEndpoint() (endpoint string, apiErr errors.Error)

func (RemoteEndpointRepository) UpdateEndpoint

func (repo RemoteEndpointRepository) UpdateEndpoint(endpoint string) (finalEndpoint string, apiErr errors.Error)

type RepositoryLocator

type RepositoryLocator struct {
	// contains filtered or unexported fields
}

func NewRepositoryLocator

func NewRepositoryLocator(config configuration.ReadWriter, gatewaysByName map[string]net.Gateway) (loc RepositoryLocator)

func (RepositoryLocator) GetAppEventsRepository

func (locator RepositoryLocator) GetAppEventsRepository() AppEventsRepository

func (RepositoryLocator) GetAppFilesRepository

func (locator RepositoryLocator) GetAppFilesRepository() AppFilesRepository

func (RepositoryLocator) GetAppInstancesRepository

func (locator RepositoryLocator) GetAppInstancesRepository() AppInstancesRepository

func (RepositoryLocator) GetAppSummaryRepository

func (locator RepositoryLocator) GetAppSummaryRepository() AppSummaryRepository

func (RepositoryLocator) GetApplicationBitsRepository

func (locator RepositoryLocator) GetApplicationBitsRepository() ApplicationBitsRepository

func (RepositoryLocator) GetApplicationRepository

func (locator RepositoryLocator) GetApplicationRepository() ApplicationRepository

func (RepositoryLocator) GetAuthenticationRepository

func (locator RepositoryLocator) GetAuthenticationRepository() AuthenticationRepository

func (RepositoryLocator) GetBuildpackBitsRepository

func (locator RepositoryLocator) GetBuildpackBitsRepository() BuildpackBitsRepository

func (RepositoryLocator) GetBuildpackRepository

func (locator RepositoryLocator) GetBuildpackRepository() BuildpackRepository

func (RepositoryLocator) GetCurlRepository

func (locator RepositoryLocator) GetCurlRepository() CurlRepository

func (RepositoryLocator) GetDomainRepository

func (locator RepositoryLocator) GetDomainRepository() DomainRepository

func (RepositoryLocator) GetEndpointRepository

func (locator RepositoryLocator) GetEndpointRepository() EndpointRepository

func (RepositoryLocator) GetLogsRepository

func (locator RepositoryLocator) GetLogsRepository() LogsRepository

func (RepositoryLocator) GetOrganizationRepository

func (locator RepositoryLocator) GetOrganizationRepository() OrganizationRepository

func (RepositoryLocator) GetPasswordRepository

func (locator RepositoryLocator) GetPasswordRepository() PasswordRepository

func (RepositoryLocator) GetQuotaRepository

func (locator RepositoryLocator) GetQuotaRepository() QuotaRepository

func (RepositoryLocator) GetRouteRepository

func (locator RepositoryLocator) GetRouteRepository() RouteRepository

func (RepositoryLocator) GetServiceAuthTokenRepository

func (locator RepositoryLocator) GetServiceAuthTokenRepository() ServiceAuthTokenRepository

func (RepositoryLocator) GetServiceBindingRepository

func (locator RepositoryLocator) GetServiceBindingRepository() ServiceBindingRepository

func (RepositoryLocator) GetServiceBrokerRepository

func (locator RepositoryLocator) GetServiceBrokerRepository() ServiceBrokerRepository

func (RepositoryLocator) GetServiceRepository

func (locator RepositoryLocator) GetServiceRepository() ServiceRepository

func (RepositoryLocator) GetServiceSummaryRepository

func (locator RepositoryLocator) GetServiceSummaryRepository() ServiceSummaryRepository

func (RepositoryLocator) GetSpaceRepository

func (locator RepositoryLocator) GetSpaceRepository() SpaceRepository

func (RepositoryLocator) GetStackRepository

func (locator RepositoryLocator) GetStackRepository() StackRepository

func (RepositoryLocator) GetUserProvidedServiceInstanceRepository

func (locator RepositoryLocator) GetUserProvidedServiceInstanceRepository() UserProvidedServiceInstanceRepository

func (RepositoryLocator) GetUserRepository

func (locator RepositoryLocator) GetUserRepository() UserRepository

type Resource

type Resource struct {
	Metadata Metadata
	Entity   Entity
}

type RouteEntity

type RouteEntity struct {
	Host   string
	Domain DomainResource
	Space  SpaceResource
	Apps   []ApplicationResource
}

type RouteRepository

type RouteRepository interface {
	ListRoutes(cb func(models.Route) bool) (apiErr errors.Error)
	FindByHost(host string) (route models.Route, apiErr errors.Error)
	FindByHostAndDomain(host, domain string) (route models.Route, apiErr errors.Error)
	Create(host, domainGuid string) (createdRoute models.Route, apiErr errors.Error)
	CreateInSpace(host, domainGuid, spaceGuid string) (createdRoute models.Route, apiErr errors.Error)
	Bind(routeGuid, appGuid string) (apiErr errors.Error)
	Unbind(routeGuid, appGuid string) (apiErr errors.Error)
	Delete(routeGuid string) (apiErr errors.Error)
}

type RouteResource

type RouteResource struct {
	Resource
	Entity RouteEntity
}

func (RouteResource) ToFields

func (resource RouteResource) ToFields() (fields models.RouteFields)

func (RouteResource) ToModel

func (resource RouteResource) ToModel() (route models.Route)

type RouteSummary

type RouteSummary struct {
	Guid   string
	Host   string
	Domain DomainSummary
}

func (RouteSummary) ToModel

func (resource RouteSummary) ToModel() (route models.RouteSummary)

type ServiceAuthTokenRepository

type ServiceAuthTokenRepository interface {
	FindAll() (authTokens []models.ServiceAuthTokenFields, apiErr errors.Error)
	FindByLabelAndProvider(label, provider string) (authToken models.ServiceAuthTokenFields, apiErr errors.Error)
	Create(authToken models.ServiceAuthTokenFields) (apiErr errors.Error)
	Update(authToken models.ServiceAuthTokenFields) (apiErr errors.Error)
	Delete(authToken models.ServiceAuthTokenFields) (apiErr errors.Error)
}

type ServiceBindingEntity

type ServiceBindingEntity struct {
	AppGuid string `json:"app_guid"`
}

type ServiceBindingRepository

type ServiceBindingRepository interface {
	Create(instanceGuid, appGuid string) (apiErr errors.Error)
	Delete(instance models.ServiceInstance, appGuid string) (found bool, apiErr errors.Error)
}

type ServiceBindingResource

type ServiceBindingResource struct {
	Metadata Metadata
	Entity   ServiceBindingEntity
}

func (ServiceBindingResource) ToFields

func (resource ServiceBindingResource) ToFields() (fields models.ServiceBindingFields)

type ServiceBrokerEntity

type ServiceBrokerEntity struct {
	Guid     string
	Name     string
	Password string `json:"auth_password"`
	Username string `json:"auth_username"`
	Url      string `json:"broker_url"`
}

type ServiceBrokerRepository

type ServiceBrokerRepository interface {
	ListServiceBrokers(callback func(models.ServiceBroker) bool) errors.Error
	FindByName(name string) (serviceBroker models.ServiceBroker, apiErr errors.Error)
	Create(name, url, username, password string) (apiErr errors.Error)
	Update(serviceBroker models.ServiceBroker) (apiErr errors.Error)
	Rename(guid, name string) (apiErr errors.Error)
	Delete(guid string) (apiErr errors.Error)
}

type ServiceBrokerResource

type ServiceBrokerResource struct {
	Resource
	Entity ServiceBrokerEntity
}

func (ServiceBrokerResource) ToFields

func (resource ServiceBrokerResource) ToFields() (fields models.ServiceBroker)

type ServiceInstanceEntity

type ServiceInstanceEntity struct {
	Name            string
	ServiceBindings []ServiceBindingResource `json:"service_bindings"`
	ServicePlan     ServicePlanResource      `json:"service_plan"`
}

type ServiceInstanceResource

type ServiceInstanceResource struct {
	Metadata Metadata
	Entity   ServiceInstanceEntity
}

func (ServiceInstanceResource) ToFields

func (resource ServiceInstanceResource) ToFields() (fields models.ServiceInstanceFields)

func (ServiceInstanceResource) ToModel

func (resource ServiceInstanceResource) ToModel() (instance models.ServiceInstance)

type ServiceInstanceSummary

type ServiceInstanceSummary struct {
	Name        string
	ServicePlan ServicePlanSummary `json:"service_plan"`
}

type ServiceInstanceSummaryApp

type ServiceInstanceSummaryApp struct {
	Name         string
	ServiceNames []string `json:"service_names"`
}

type ServiceInstancesSummaries

type ServiceInstancesSummaries struct {
	Apps             []ServiceInstanceSummaryApp
	ServiceInstances []ServiceInstanceSummary `json:"services"`
}

func (ServiceInstancesSummaries) ToModels

func (resource ServiceInstancesSummaries) ToModels() (instances []models.ServiceInstance)

type ServiceMigrateV1ToV2Response

type ServiceMigrateV1ToV2Response struct {
	ChangedCount int `json:"changed_count"`
}

type ServiceOfferingEntity

type ServiceOfferingEntity struct {
	Label            string
	Version          string
	Description      string
	DocumentationUrl string `json:"documentation_url"`
	Provider         string
	ServicePlans     []ServicePlanResource `json:"service_plans"`
}

type ServiceOfferingResource

type ServiceOfferingResource struct {
	Metadata Metadata
	Entity   ServiceOfferingEntity
}

func (ServiceOfferingResource) ToFields

func (resource ServiceOfferingResource) ToFields() (fields models.ServiceOfferingFields)

func (ServiceOfferingResource) ToModel

func (resource ServiceOfferingResource) ToModel() (offering models.ServiceOffering)

type ServiceOfferingSummary

type ServiceOfferingSummary struct {
	Label    string
	Provider string
	Version  string
}

type ServicePlanDescription

type ServicePlanDescription struct {
	ServiceLabel    string
	ServicePlanName string
	ServiceProvider string
}

func (ServicePlanDescription) String

func (planDesc ServicePlanDescription) String() string

type ServicePlanEntity

type ServicePlanEntity struct {
	Name                string
	ServiceOfferingGuid string                  `json:"service_guid"`
	ServiceOffering     ServiceOfferingResource `json:"service"`
}

type ServicePlanResource

type ServicePlanResource struct {
	Metadata Metadata
	Entity   ServicePlanEntity
}

func (ServicePlanResource) ToFields

func (resource ServicePlanResource) ToFields() (fields models.ServicePlanFields)

type ServicePlanSummary

type ServicePlanSummary struct {
	Name            string
	Guid            string
	ServiceOffering ServiceOfferingSummary `json:"service"`
}

type ServiceRepository

type ServiceRepository interface {
	PurgeServiceOffering(offering models.ServiceOffering) errors.Error
	FindServiceOfferingByLabelAndProvider(name, provider string) (offering models.ServiceOffering, apiErr errors.Error)
	GetAllServiceOfferings() (offerings models.ServiceOfferings, apiErr errors.Error)
	GetServiceOfferingsForSpace(spaceGuid string) (offerings models.ServiceOfferings, apiErr errors.Error)
	FindInstanceByName(name string) (instance models.ServiceInstance, apiErr errors.Error)
	CreateServiceInstance(name, planGuid string) (identicalAlreadyExists bool, apiErr errors.Error)
	RenameService(instance models.ServiceInstance, newName string) (apiErr errors.Error)
	DeleteService(instance models.ServiceInstance) (apiErr errors.Error)
	FindServicePlanByDescription(planDescription ServicePlanDescription) (planGuid string, apiErr errors.Error)
	GetServiceInstanceCountForServicePlan(v1PlanGuid string) (count int, apiErr errors.Error)
	MigrateServicePlanFromV1ToV2(v1PlanGuid, v2PlanGuid string) (changedCount int, apiErr errors.Error)
}

type ServiceSummaryRepository

type ServiceSummaryRepository interface {
	GetSummariesInCurrentSpace() (instances []models.ServiceInstance, apiErr errors.Error)
}

type SortedMessageQueue

type SortedMessageQueue struct {
	// contains filtered or unexported fields
}

func NewSortedMessageQueue

func NewSortedMessageQueue(printTimeBuffer time.Duration, clock func() time.Time) *SortedMessageQueue

func (*SortedMessageQueue) NextTimestamp

func (pq *SortedMessageQueue) NextTimestamp() int64

func (*SortedMessageQueue) PopMessage

func (pq *SortedMessageQueue) PopMessage() *logmessage.Message

func (*SortedMessageQueue) PushMessage

func (pq *SortedMessageQueue) PushMessage(message *logmessage.Message)

type SpaceEntity

type SpaceEntity struct {
	Name             string
	Organization     OrganizationResource
	Applications     []ApplicationResource `json:"apps"`
	Domains          []DomainResource
	ServiceInstances []ServiceInstanceResource `json:"service_instances"`
}

type SpaceRepository

type SpaceRepository interface {
	ListSpaces(func(models.Space) bool) errors.Error
	FindByName(name string) (space models.Space, apiErr errors.Error)
	FindByNameInOrg(name, orgGuid string) (space models.Space, apiErr errors.Error)
	Create(name string, orgGuid string) (space models.Space, apiErr errors.Error)
	Rename(spaceGuid, newName string) (apiErr errors.Error)
	Delete(spaceGuid string) (apiErr errors.Error)
}

type SpaceResource

type SpaceResource struct {
	Metadata Metadata
	Entity   SpaceEntity
}

func (SpaceResource) ToFields

func (resource SpaceResource) ToFields() (fields models.SpaceFields)

func (SpaceResource) ToModel

func (resource SpaceResource) ToModel() (space models.Space)

type StackEntity

type StackEntity struct {
	Name        string
	Description string
}

type StackRepository

type StackRepository interface {
	FindByName(name string) (stack models.Stack, apiErr errors.Error)
	FindAll() (stacks []models.Stack, apiErr errors.Error)
}

type StackResource

type StackResource struct {
	Resource
	Entity StackEntity
}

func (StackResource) ToFields

func (resource StackResource) ToFields() (fields models.Stack)

type StatsApiResponse

type StatsApiResponse map[string]InstanceStatsApiResponse

type UAAAuthenticationRepository

type UAAAuthenticationRepository struct {
	// contains filtered or unexported fields
}

func NewUAAAuthenticationRepository

func NewUAAAuthenticationRepository(gateway net.Gateway, config configuration.ReadWriter) (uaa UAAAuthenticationRepository)

func (UAAAuthenticationRepository) Authenticate

func (uaa UAAAuthenticationRepository) Authenticate(credentials map[string]string) (apiErr errors.Error)

func (UAAAuthenticationRepository) GetLoginPrompts

func (uaa UAAAuthenticationRepository) GetLoginPrompts() (prompts map[string]configuration.AuthPrompt, apiErr errors.Error)

func (UAAAuthenticationRepository) RefreshAuthToken

func (uaa UAAAuthenticationRepository) RefreshAuthToken() (updatedToken string, apiErr errors.Error)

type UAAUserResources

type UAAUserResources struct {
	Resources []struct {
		Id       string
		Username string
	}
}

type UserEntity

type UserEntity struct {
	Entity
	Admin bool
}

type UserProvidedServiceInstanceRepository

type UserProvidedServiceInstanceRepository interface {
	Create(name, drainUrl string, params map[string]string) (apiErr errors.Error)
	Update(serviceInstanceFields models.ServiceInstanceFields) (apiErr errors.Error)
}

type UserRepository

type UserRepository interface {
	FindByUsername(username string) (user models.UserFields, apiErr errors.Error)
	ListUsersInOrgForRole(orgGuid string, role string) ([]models.UserFields, errors.Error)
	ListUsersInSpaceForRole(spaceGuid string, role string) ([]models.UserFields, errors.Error)
	Create(username, password string) (apiErr errors.Error)
	Delete(userGuid string) (apiErr errors.Error)
	SetOrgRole(userGuid, orgGuid, role string) (apiErr errors.Error)
	UnsetOrgRole(userGuid, orgGuid, role string) (apiErr errors.Error)
	SetSpaceRole(userGuid, spaceGuid, orgGuid, role string) (apiErr errors.Error)
	UnsetSpaceRole(userGuid, spaceGuid, role string) (apiErr errors.Error)
}

type UserResource

type UserResource struct {
	Resource
	Entity UserEntity
}

func (UserResource) ToFields

func (resource UserResource) ToFields() models.UserFields

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL