space

package
v0.0.0-...-10dff14 Latest Latest
Warning

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

Go to latest
Published: Jan 6, 2023 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_proto_planetdetails_proto protoreflect.FileDescriptor
View Source
var File_proto_planetlist_proto protoreflect.FileDescriptor
View Source
var File_proto_planetservices_proto protoreflect.FileDescriptor
View Source
var File_proto_planetwelcome_proto protoreflect.FileDescriptor
View Source
var File_proto_secrets_proto protoreflect.FileDescriptor
View Source
var PlanetService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "space.PlanetService",
	HandlerType: (*PlanetServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "getWelcome",
			Handler:    _PlanetService_GetWelcome_Handler,
		},
		{
			MethodName: "getPlanetList",
			Handler:    _PlanetService_GetPlanetList_Handler,
		},
		{
			MethodName: "getPlanetDetails",
			Handler:    _PlanetService_GetPlanetDetails_Handler,
		},
		{
			MethodName: "getSecrets",
			Handler:    _PlanetService_GetSecrets_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "proto/planetservices.proto",
}

PlanetService_ServiceDesc is the grpc.ServiceDesc for PlanetService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterPlanetServiceServer

func RegisterPlanetServiceServer(s grpc.ServiceRegistrar, srv PlanetServiceServer)

Types

type ApisSecrets

type ApisSecrets struct {
	Host     string `protobuf:"bytes,1,opt,name=host,proto3" json:"host,omitempty"`
	Username string `protobuf:"bytes,2,opt,name=username,proto3" json:"username,omitempty"`
	Password string `protobuf:"bytes,3,opt,name=password,proto3" json:"password,omitempty"`
	// contains filtered or unexported fields
}

func (*ApisSecrets) Descriptor deprecated

func (*ApisSecrets) Descriptor() ([]byte, []int)

Deprecated: Use ApisSecrets.ProtoReflect.Descriptor instead.

func (*ApisSecrets) GetHost

func (x *ApisSecrets) GetHost() string

func (*ApisSecrets) GetPassword

func (x *ApisSecrets) GetPassword() string

func (*ApisSecrets) GetUsername

func (x *ApisSecrets) GetUsername() string

func (*ApisSecrets) ProtoMessage

func (*ApisSecrets) ProtoMessage()

func (*ApisSecrets) ProtoReflect

func (x *ApisSecrets) ProtoReflect() protoreflect.Message

func (*ApisSecrets) Reset

func (x *ApisSecrets) Reset()

func (*ApisSecrets) String

func (x *ApisSecrets) String() string

type DatabaseSecrets

type DatabaseSecrets struct {
	Username string `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"`
	Password string `protobuf:"bytes,2,opt,name=password,proto3" json:"password,omitempty"`
	// contains filtered or unexported fields
}

func (*DatabaseSecrets) Descriptor deprecated

func (*DatabaseSecrets) Descriptor() ([]byte, []int)

Deprecated: Use DatabaseSecrets.ProtoReflect.Descriptor instead.

func (*DatabaseSecrets) GetPassword

func (x *DatabaseSecrets) GetPassword() string

func (*DatabaseSecrets) GetUsername

func (x *DatabaseSecrets) GetUsername() string

func (*DatabaseSecrets) ProtoMessage

func (*DatabaseSecrets) ProtoMessage()

func (*DatabaseSecrets) ProtoReflect

func (x *DatabaseSecrets) ProtoReflect() protoreflect.Message

func (*DatabaseSecrets) Reset

func (x *DatabaseSecrets) Reset()

func (*DatabaseSecrets) String

func (x *DatabaseSecrets) String() string

type Density

type Density struct {
	Value      string `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"`
	MetricUnit string `protobuf:"bytes,2,opt,name=metric_unit,json=metricUnit,proto3" json:"metric_unit,omitempty"`
	// contains filtered or unexported fields
}

func (*Density) Descriptor deprecated

func (*Density) Descriptor() ([]byte, []int)

Deprecated: Use Density.ProtoReflect.Descriptor instead.

func (*Density) GetMetricUnit

func (x *Density) GetMetricUnit() string

func (*Density) GetValue

func (x *Density) GetValue() string

func (*Density) ProtoMessage

func (*Density) ProtoMessage()

func (*Density) ProtoReflect

func (x *Density) ProtoReflect() protoreflect.Message

func (*Density) Reset

func (x *Density) Reset()

func (*Density) String

func (x *Density) String() string

type EquatorialRadius

type EquatorialRadius struct {
	Value      string `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"`
	MetricUnit string `protobuf:"bytes,2,opt,name=metric_unit,json=metricUnit,proto3" json:"metric_unit,omitempty"`
	// contains filtered or unexported fields
}

func (*EquatorialRadius) Descriptor deprecated

func (*EquatorialRadius) Descriptor() ([]byte, []int)

Deprecated: Use EquatorialRadius.ProtoReflect.Descriptor instead.

func (*EquatorialRadius) GetMetricUnit

func (x *EquatorialRadius) GetMetricUnit() string

func (*EquatorialRadius) GetValue

func (x *EquatorialRadius) GetValue() string

func (*EquatorialRadius) ProtoMessage

func (*EquatorialRadius) ProtoMessage()

func (*EquatorialRadius) ProtoReflect

func (x *EquatorialRadius) ProtoReflect() protoreflect.Message

func (*EquatorialRadius) Reset

func (x *EquatorialRadius) Reset()

func (*EquatorialRadius) String

func (x *EquatorialRadius) String() string

type GrpcWelcomeMessage

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

func (*GrpcWelcomeMessage) BuildResponse

func (wm *GrpcWelcomeMessage) BuildResponse() *WelcomeMessage

func (*GrpcWelcomeMessage) CreateWelcomeMessage

func (wm *GrpcWelcomeMessage) CreateWelcomeMessage()

func (*GrpcWelcomeMessage) WithCorrelationId

func (wm *GrpcWelcomeMessage) WithCorrelationId(correlationId string)

func (*GrpcWelcomeMessage) WithPayload

func (wm *GrpcWelcomeMessage) WithPayload(payload *WelcomePayload)

func (*GrpcWelcomeMessage) WithTimestamp

func (wm *GrpcWelcomeMessage) WithTimestamp(timestamp string)

type GrpcWelcomeMessageInterface

type GrpcWelcomeMessageInterface interface {
	CrateWelcomeMessage()
	WithCorrelationId(correlationId string)
	WithTimestamp(timestamp string)
	WithPayload(*WelcomePayload)
	BuildResponse() *WelcomeMessage
}

type GrpcWelcomePayload

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

func (*GrpcWelcomePayload) BuildResponse

func (wp *GrpcWelcomePayload) BuildResponse() *WelcomePayload

func (*GrpcWelcomePayload) CreateWelcomePayload

func (wp *GrpcWelcomePayload) CreateWelcomePayload()

func (*GrpcWelcomePayload) WithInternalCode

func (wp *GrpcWelcomePayload) WithInternalCode(code int)

func (*GrpcWelcomePayload) WithMessage

func (wp *GrpcWelcomePayload) WithMessage(message string)

type GrpcWelcomePayloadInterface

type GrpcWelcomePayloadInterface interface {
	CreateWelcomePayload()
	WithInternalCode(code int)
	WithMessage(message string)
	BuildResponse() *WelcomePayload
}

type Mass

type Mass struct {
	Value      string `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"`
	MetricUnit string `protobuf:"bytes,2,opt,name=metric_unit,json=metricUnit,proto3" json:"metric_unit,omitempty"`
	// contains filtered or unexported fields
}

func (*Mass) Descriptor deprecated

func (*Mass) Descriptor() ([]byte, []int)

Deprecated: Use Mass.ProtoReflect.Descriptor instead.

func (*Mass) GetMetricUnit

func (x *Mass) GetMetricUnit() string

func (*Mass) GetValue

func (x *Mass) GetValue() string

func (*Mass) ProtoMessage

func (*Mass) ProtoMessage()

func (*Mass) ProtoReflect

func (x *Mass) ProtoReflect() protoreflect.Message

func (*Mass) Reset

func (x *Mass) Reset()

func (*Mass) String

func (x *Mass) String() string

type PlanetDetails

type PlanetDetails struct {
	Id               int32             `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Name             string            `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	Type             string            `protobuf:"bytes,3,opt,name=type,proto3" json:"type,omitempty"`
	EquatorialRadius *EquatorialRadius `protobuf:"bytes,4,opt,name=equatorial_radius,json=equatorialRadius,proto3" json:"equatorial_radius,omitempty"`
	Mass             *Mass             `protobuf:"bytes,5,opt,name=mass,proto3" json:"mass,omitempty"`
	Volume           *Volume           `protobuf:"bytes,6,opt,name=volume,proto3" json:"volume,omitempty"`
	Density          *Density          `protobuf:"bytes,7,opt,name=density,proto3" json:"density,omitempty"`
	Satellites       []string          `protobuf:"bytes,8,rep,name=satellites,proto3" json:"satellites,omitempty"`
	// contains filtered or unexported fields
}

func BuildPlanetDetails

func BuildPlanetDetails(raw []byte, correlationId string) (*PlanetDetails, error)

func (*PlanetDetails) Descriptor deprecated

func (*PlanetDetails) Descriptor() ([]byte, []int)

Deprecated: Use PlanetDetails.ProtoReflect.Descriptor instead.

func (*PlanetDetails) GetDensity

func (x *PlanetDetails) GetDensity() *Density

func (*PlanetDetails) GetEquatorialRadius

func (x *PlanetDetails) GetEquatorialRadius() *EquatorialRadius

func (*PlanetDetails) GetId

func (x *PlanetDetails) GetId() int32

func (*PlanetDetails) GetMass

func (x *PlanetDetails) GetMass() *Mass

func (*PlanetDetails) GetName

func (x *PlanetDetails) GetName() string

func (*PlanetDetails) GetSatellites

func (x *PlanetDetails) GetSatellites() []string

func (*PlanetDetails) GetType

func (x *PlanetDetails) GetType() string

func (*PlanetDetails) GetVolume

func (x *PlanetDetails) GetVolume() *Volume

func (*PlanetDetails) ProtoMessage

func (*PlanetDetails) ProtoMessage()

func (*PlanetDetails) ProtoReflect

func (x *PlanetDetails) ProtoReflect() protoreflect.Message

func (*PlanetDetails) Reset

func (x *PlanetDetails) Reset()

func (*PlanetDetails) String

func (x *PlanetDetails) String() string

type PlanetList

type PlanetList struct {
	PlanetList []*PlanetListItem `protobuf:"bytes,1,rep,name=planetList,proto3" json:"planetList,omitempty"`
	// contains filtered or unexported fields
}

func BuildPlanetList

func BuildPlanetList(raw []byte, correlationId string) (*PlanetList, error)

func (*PlanetList) Descriptor deprecated

func (*PlanetList) Descriptor() ([]byte, []int)

Deprecated: Use PlanetList.ProtoReflect.Descriptor instead.

func (*PlanetList) GetPlanetList

func (x *PlanetList) GetPlanetList() []*PlanetListItem

func (*PlanetList) ProtoMessage

func (*PlanetList) ProtoMessage()

func (*PlanetList) ProtoReflect

func (x *PlanetList) ProtoReflect() protoreflect.Message

func (*PlanetList) Reset

func (x *PlanetList) Reset()

func (*PlanetList) String

func (x *PlanetList) String() string

type PlanetListItem

type PlanetListItem struct {
	Id   int32  `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

func (*PlanetListItem) Descriptor deprecated

func (*PlanetListItem) Descriptor() ([]byte, []int)

Deprecated: Use PlanetListItem.ProtoReflect.Descriptor instead.

func (*PlanetListItem) GetId

func (x *PlanetListItem) GetId() int32

func (*PlanetListItem) GetName

func (x *PlanetListItem) GetName() string

func (*PlanetListItem) ProtoMessage

func (*PlanetListItem) ProtoMessage()

func (*PlanetListItem) ProtoReflect

func (x *PlanetListItem) ProtoReflect() protoreflect.Message

func (*PlanetListItem) Reset

func (x *PlanetListItem) Reset()

func (*PlanetListItem) String

func (x *PlanetListItem) String() string

type PlanetServer

type PlanetServer struct{}

func (*PlanetServer) GetPlanetDetails

func (*PlanetServer) GetPlanetDetails(ctx context.Context, param *wrapperspb.StringValue) (*PlanetDetails, error)

func (*PlanetServer) GetPlanetList

func (*PlanetServer) GetPlanetList(context.Context, *emptypb.Empty) (*PlanetList, error)

func (*PlanetServer) GetSecrets

func (*PlanetServer) GetWelcome

type PlanetServiceClient

type PlanetServiceClient interface {
	GetWelcome(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*WelcomeMessage, error)
	GetPlanetList(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*PlanetList, error)
	GetPlanetDetails(ctx context.Context, in *wrapperspb.StringValue, opts ...grpc.CallOption) (*PlanetDetails, error)
	GetSecrets(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*SecretMessage, error)
}

PlanetServiceClient is the client API for PlanetService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type PlanetServiceServer

type PlanetServiceServer interface {
	GetWelcome(context.Context, *emptypb.Empty) (*WelcomeMessage, error)
	GetPlanetList(context.Context, *emptypb.Empty) (*PlanetList, error)
	GetPlanetDetails(context.Context, *wrapperspb.StringValue) (*PlanetDetails, error)
	GetSecrets(context.Context, *emptypb.Empty) (*SecretMessage, error)
	// contains filtered or unexported methods
}

PlanetServiceServer is the server API for PlanetService service. All implementations must embed UnimplementedPlanetServiceServer for forward compatibility

type SecretDetails

type SecretDetails struct {
	Enable bool             `protobuf:"varint,1,opt,name=enable,proto3" json:"enable,omitempty"`
	Db     *DatabaseSecrets `protobuf:"bytes,2,opt,name=db,proto3" json:"db,omitempty"`
	Apis   []*ApisSecrets   `protobuf:"bytes,3,rep,name=apis,proto3" json:"apis,omitempty"`
	// contains filtered or unexported fields
}

func (*SecretDetails) Descriptor deprecated

func (*SecretDetails) Descriptor() ([]byte, []int)

Deprecated: Use SecretDetails.ProtoReflect.Descriptor instead.

func (*SecretDetails) GetApis

func (x *SecretDetails) GetApis() []*ApisSecrets

func (*SecretDetails) GetDb

func (x *SecretDetails) GetDb() *DatabaseSecrets

func (*SecretDetails) GetEnable

func (x *SecretDetails) GetEnable() bool

func (*SecretDetails) ProtoMessage

func (*SecretDetails) ProtoMessage()

func (*SecretDetails) ProtoReflect

func (x *SecretDetails) ProtoReflect() protoreflect.Message

func (*SecretDetails) Reset

func (x *SecretDetails) Reset()

func (*SecretDetails) String

func (x *SecretDetails) String() string

type SecretMessage

type SecretMessage struct {
	CorrelationId string         `protobuf:"bytes,1,opt,name=correlation_id,json=correlationId,proto3" json:"correlation_id,omitempty"`
	Timestamp     string         `protobuf:"bytes,2,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	Payload       *SecretPayload `protobuf:"bytes,3,opt,name=payload,proto3" json:"payload,omitempty"`
	// contains filtered or unexported fields
}

func BuildSecrets

func BuildSecrets(secrets *config.SecretConfig, internalCode int, correlationId string) *SecretMessage

func (*SecretMessage) Descriptor deprecated

func (*SecretMessage) Descriptor() ([]byte, []int)

Deprecated: Use SecretMessage.ProtoReflect.Descriptor instead.

func (*SecretMessage) GetCorrelationId

func (x *SecretMessage) GetCorrelationId() string

func (*SecretMessage) GetPayload

func (x *SecretMessage) GetPayload() *SecretPayload

func (*SecretMessage) GetTimestamp

func (x *SecretMessage) GetTimestamp() string

func (*SecretMessage) ProtoMessage

func (*SecretMessage) ProtoMessage()

func (*SecretMessage) ProtoReflect

func (x *SecretMessage) ProtoReflect() protoreflect.Message

func (*SecretMessage) Reset

func (x *SecretMessage) Reset()

func (*SecretMessage) String

func (x *SecretMessage) String() string

type SecretPayload

type SecretPayload struct {
	InternalCode int32    `protobuf:"varint,1,opt,name=internal_code,json=internalCode,proto3" json:"internal_code,omitempty"`
	Message      *Secrets `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
	// contains filtered or unexported fields
}

func (*SecretPayload) Descriptor deprecated

func (*SecretPayload) Descriptor() ([]byte, []int)

Deprecated: Use SecretPayload.ProtoReflect.Descriptor instead.

func (*SecretPayload) GetInternalCode

func (x *SecretPayload) GetInternalCode() int32

func (*SecretPayload) GetMessage

func (x *SecretPayload) GetMessage() *Secrets

func (*SecretPayload) ProtoMessage

func (*SecretPayload) ProtoMessage()

func (*SecretPayload) ProtoReflect

func (x *SecretPayload) ProtoReflect() protoreflect.Message

func (*SecretPayload) Reset

func (x *SecretPayload) Reset()

func (*SecretPayload) String

func (x *SecretPayload) String() string

type Secrets

type Secrets struct {
	Secrets *SecretDetails `protobuf:"bytes,1,opt,name=secrets,proto3" json:"secrets,omitempty"`
	// contains filtered or unexported fields
}

func (*Secrets) Descriptor deprecated

func (*Secrets) Descriptor() ([]byte, []int)

Deprecated: Use Secrets.ProtoReflect.Descriptor instead.

func (*Secrets) GetSecrets

func (x *Secrets) GetSecrets() *SecretDetails

func (*Secrets) ProtoMessage

func (*Secrets) ProtoMessage()

func (*Secrets) ProtoReflect

func (x *Secrets) ProtoReflect() protoreflect.Message

func (*Secrets) Reset

func (x *Secrets) Reset()

func (*Secrets) String

func (x *Secrets) String() string

type UnimplementedPlanetServiceServer

type UnimplementedPlanetServiceServer struct {
}

UnimplementedPlanetServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedPlanetServiceServer) GetPlanetDetails

func (UnimplementedPlanetServiceServer) GetPlanetList

func (UnimplementedPlanetServiceServer) GetSecrets

func (UnimplementedPlanetServiceServer) GetWelcome

type UnsafePlanetServiceServer

type UnsafePlanetServiceServer interface {
	// contains filtered or unexported methods
}

UnsafePlanetServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to PlanetServiceServer will result in compilation errors.

type Volume

type Volume struct {
	Value      string `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"`
	MetricUnit string `protobuf:"bytes,2,opt,name=metric_unit,json=metricUnit,proto3" json:"metric_unit,omitempty"`
	// contains filtered or unexported fields
}

func (*Volume) Descriptor deprecated

func (*Volume) Descriptor() ([]byte, []int)

Deprecated: Use Volume.ProtoReflect.Descriptor instead.

func (*Volume) GetMetricUnit

func (x *Volume) GetMetricUnit() string

func (*Volume) GetValue

func (x *Volume) GetValue() string

func (*Volume) ProtoMessage

func (*Volume) ProtoMessage()

func (*Volume) ProtoReflect

func (x *Volume) ProtoReflect() protoreflect.Message

func (*Volume) Reset

func (x *Volume) Reset()

func (*Volume) String

func (x *Volume) String() string

type WelcomeMessage

type WelcomeMessage struct {
	CorrelationId string          `protobuf:"bytes,1,opt,name=correlation_id,json=correlationId,proto3" json:"correlation_id,omitempty"`
	Timestamp     string          `protobuf:"bytes,2,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	Payload       *WelcomePayload `protobuf:"bytes,3,opt,name=payload,proto3" json:"payload,omitempty"`
	// contains filtered or unexported fields
}

func BuildGrpcWelcomeMessage

func BuildGrpcWelcomeMessage(correlationId string, timestamp string, internalCode int, message string) *WelcomeMessage

func (*WelcomeMessage) Descriptor deprecated

func (*WelcomeMessage) Descriptor() ([]byte, []int)

Deprecated: Use WelcomeMessage.ProtoReflect.Descriptor instead.

func (*WelcomeMessage) GetCorrelationId

func (x *WelcomeMessage) GetCorrelationId() string

func (*WelcomeMessage) GetPayload

func (x *WelcomeMessage) GetPayload() *WelcomePayload

func (*WelcomeMessage) GetTimestamp

func (x *WelcomeMessage) GetTimestamp() string

func (*WelcomeMessage) ProtoMessage

func (*WelcomeMessage) ProtoMessage()

func (*WelcomeMessage) ProtoReflect

func (x *WelcomeMessage) ProtoReflect() protoreflect.Message

func (*WelcomeMessage) Reset

func (x *WelcomeMessage) Reset()

func (*WelcomeMessage) String

func (x *WelcomeMessage) String() string

type WelcomePayload

type WelcomePayload struct {
	InternalCode int32  `protobuf:"varint,1,opt,name=internal_code,json=internalCode,proto3" json:"internal_code,omitempty"`
	Message      string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
	// contains filtered or unexported fields
}

func (*WelcomePayload) Descriptor deprecated

func (*WelcomePayload) Descriptor() ([]byte, []int)

Deprecated: Use WelcomePayload.ProtoReflect.Descriptor instead.

func (*WelcomePayload) GetInternalCode

func (x *WelcomePayload) GetInternalCode() int32

func (*WelcomePayload) GetMessage

func (x *WelcomePayload) GetMessage() string

func (*WelcomePayload) ProtoMessage

func (*WelcomePayload) ProtoMessage()

func (*WelcomePayload) ProtoReflect

func (x *WelcomePayload) ProtoReflect() protoreflect.Message

func (*WelcomePayload) Reset

func (x *WelcomePayload) Reset()

func (*WelcomePayload) String

func (x *WelcomePayload) String() string

Jump to

Keyboard shortcuts

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