Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Attribute ¶
type Attribute interface { Computed() bool DefaultValue() string Deprecation() string Description() string ElementType() string Field() *protogen.Field HasNestedType() bool IsPointer() bool MdDescription() string Name() string NeedsDefaultValue() bool Optional() bool Required() bool Schema() *pb.GoIdentity Sensitive() bool TypeValue() TypeValue }
type Block ¶
type Block interface { Clients() []string Description() string ExecFilename() string ExecGoName() string Filename() string GoName() string HasServiceClient() bool IsDataSource() bool IsResource() bool Model() Model ModelGoName() string Option() *pb.Block TerraformName() string Type() protoreflect.ExtensionType TypeName() string }
Block is helper to gocode a terraform block.
//go:gocode mockery --name Block --output ../../mocks.
type PackageData ¶ added in v0.3.0
type PackageData struct { ExecImportPath protogen.GoImportPath ExecPackageName protogen.GoPackageName PbImportPath protogen.GoImportPath PbPackageName protogen.GoPackageName ProviderImportPath protogen.GoImportPath ProviderPackageName protogen.GoPackageName }
type Provider ¶
type Provider interface { AddDatasource(string, string) AddResource(string, string) Datasources() map[string]string Description() string ExecFilename() string ExecGoName() string Filename() string GoName() string HasServiceClient() bool Model() Model ModelGoName() string Option() *pb.Provider PackageData() PackageData Resources() map[string]string SetHasServiceClient(bool) TerraformName() string }
Provider is helper to gocode a terraform provider.
//go:gocode mockery --name Provider --output ../../mocks.
type Synthesizer ¶
type Synthesizer interface { Block(msg *protogen.Message, blockType protoreflect.ExtensionType) (Block, error) Attribute(field *protogen.Field, explicit bool) (Attribute, error) Datasource(msg *protogen.Message) (Block, error) FieldOption(desc protoreflect.FieldDescriptor) *pb.Attribute ProviderOption(desc protoreflect.MessageDescriptor) *pb.Provider MessageOption(desc protoreflect.MessageDescriptor, extType protoreflect.ExtensionType) *pb.Block Provider(msg *protogen.Message) (Provider, error) Resource(msg *protogen.Message) (Block, error) Model(msg *protogen.Message, explicit bool) (Model, error) Module() string MessagePackageName(msg *protogen.Message) protogen.GoPackageName MessageImportPath(msg *protogen.Message) protogen.GoImportPath }
Synthesizer for synthesizing Provider or resource, datasource Block from proto files, messages.
//go:gocode mockery --name Synthesizer --output ../../mocks.
Click to show internal directories.
Click to hide internal directories.