Documentation ¶
Index ¶
- func GetAllResources[T Resource](ctx MultyContext) []T
- func GetAllResourcesInCloud[T Resource](ctx MultyContext, cloud commonpb.CloudProvider) []T
- func GetCloudSpecificResourceId(r Resource, cloud commonpb.CloudProvider) string
- func GetMainOutputId(r Resource) (string, error)
- func GetResourceIdForCloud(resourceId string, cloud commonpb.CloudProvider) string
- type ChildResourceWithId
- func (r *ChildResourceWithId[A, B]) GetCloud() commonpb.CloudProvider
- func (r *ChildResourceWithId[A, B]) GetCloudSpecificLocation() string
- func (r ChildResourceWithId[A, B]) GetResourceId() string
- func (r ChildResourceWithId[A, B]) NewValidationError(err string, field string) validate.ValidationError
- type CloudSpecificResource
- type MultyContext
- type Resource
- type ResourceWithId
- func (r *ResourceWithId[T]) GetCloud() commonpb.CloudProvider
- func (r *ResourceWithId[T]) GetCloudSpecificLocation() string
- func (r *ResourceWithId[T]) GetLocation() string
- func (r *ResourceWithId[T]) GetResourceId() string
- func (r ResourceWithId[T]) NewValidationError(err string, field string) validate.ValidationError
- func (r *ResourceWithId[T]) Validate() (errs []validate.ValidationError)
- type Resources
- type WithChildCommonParams
- type WithCommonParams
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetAllResources ¶
func GetAllResources[T Resource](ctx MultyContext) []T
func GetAllResourcesInCloud ¶
func GetAllResourcesInCloud[T Resource](ctx MultyContext, cloud commonpb.CloudProvider) []T
func GetCloudSpecificResourceId ¶
func GetCloudSpecificResourceId(r Resource, cloud commonpb.CloudProvider) string
func GetMainOutputId ¶
func GetResourceIdForCloud ¶
func GetResourceIdForCloud(resourceId string, cloud commonpb.CloudProvider) string
Types ¶
type ChildResourceWithId ¶ added in v0.1.15
type ChildResourceWithId[ParentT Resource, ChildT WithChildCommonParams] struct { ResourceId string Args ChildT Parent ParentT }
func (*ChildResourceWithId[A, B]) GetCloud ¶ added in v0.1.15
func (r *ChildResourceWithId[A, B]) GetCloud() commonpb.CloudProvider
func (*ChildResourceWithId[A, B]) GetCloudSpecificLocation ¶ added in v0.1.15
func (r *ChildResourceWithId[A, B]) GetCloudSpecificLocation() string
func (ChildResourceWithId[A, B]) GetResourceId ¶ added in v0.1.15
func (r ChildResourceWithId[A, B]) GetResourceId() string
func (ChildResourceWithId[A, B]) NewValidationError ¶ added in v0.1.15
func (r ChildResourceWithId[A, B]) NewValidationError(err string, field string) validate.ValidationError
type CloudSpecificResource ¶
type CloudSpecificResource struct { Cloud commonpb.CloudProvider Resource Resource ImplicitlyCreated bool }
func (*CloudSpecificResource) GetLocation ¶
func (c *CloudSpecificResource) GetLocation(ctx MultyContext) string
func (*CloudSpecificResource) GetMainOutputId ¶
func (c *CloudSpecificResource) GetMainOutputId() (string, error)
func (*CloudSpecificResource) GetResourceId ¶
func (c *CloudSpecificResource) GetResourceId() string
func (*CloudSpecificResource) Translate ¶
func (c *CloudSpecificResource) Translate(ctx MultyContext) ([]output.TfBlock, error)
type MultyContext ¶
type Resource ¶
type Resource interface { Translate(ctx MultyContext) ([]output.TfBlock, error) GetResourceId() string GetCloudSpecificLocation() string Validate(ctx MultyContext) []validate.ValidationError GetMainResourceName() (string, error) GetCloud() commonpb.CloudProvider }
type ResourceWithId ¶ added in v0.1.15
type ResourceWithId[T WithCommonParams] struct { ResourceId string Args T }
func (*ResourceWithId[T]) GetCloud ¶ added in v0.1.15
func (r *ResourceWithId[T]) GetCloud() commonpb.CloudProvider
func (*ResourceWithId[T]) GetCloudSpecificLocation ¶ added in v0.1.15
func (r *ResourceWithId[T]) GetCloudSpecificLocation() string
func (*ResourceWithId[T]) GetLocation ¶ added in v0.1.15
func (r *ResourceWithId[T]) GetLocation() string
func (*ResourceWithId[T]) GetResourceId ¶ added in v0.1.15
func (r *ResourceWithId[T]) GetResourceId() string
func (ResourceWithId[T]) NewValidationError ¶ added in v0.1.15
func (r ResourceWithId[T]) NewValidationError(err string, field string) validate.ValidationError
func (*ResourceWithId[T]) Validate ¶ added in v0.1.15
func (r *ResourceWithId[T]) Validate() (errs []validate.ValidationError)
type WithChildCommonParams ¶ added in v0.1.15
type WithChildCommonParams interface {
GetCommonParameters() *commonpb.ChildResourceCommonArgs
}
type WithCommonParams ¶ added in v0.1.15
type WithCommonParams interface {
GetCommonParameters() *commonpb.ResourceCommonArgs
}
Click to show internal directories.
Click to hide internal directories.