Documentation
¶
Index ¶
- Constants
- Variables
- func RegisterDaoServer(s grpc.ServiceRegistrar, srv DaoServer)
- func RegisterProposalServer(s grpc.ServiceRegistrar, srv ProposalServer)
- type DaoByIDRequest
- type DaoByIDResponse
- type DaoClient
- type DaoInfo
- func (*DaoInfo) Descriptor() ([]byte, []int)deprecated
- func (x *DaoInfo) GetAlias() string
- func (x *DaoInfo) GetAvatar() string
- func (x *DaoInfo) GetCreatedAt() *timestamppb.Timestamp
- func (x *DaoInfo) GetId() string
- func (x *DaoInfo) GetName() string
- func (x *DaoInfo) GetPopularityIndex() float64
- func (x *DaoInfo) GetUpdatedAt() *timestamppb.Timestamp
- func (x *DaoInfo) GetVerified() bool
- func (*DaoInfo) ProtoMessage()
- func (x *DaoInfo) ProtoReflect() protoreflect.Message
- func (x *DaoInfo) Reset()
- func (x *DaoInfo) String() string
- type DaoServer
- type ProposalByFilterRequest
- func (*ProposalByFilterRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ProposalByFilterRequest) GetDao() string
- func (x *ProposalByFilterRequest) GetLimit() uint64
- func (x *ProposalByFilterRequest) GetOffset() uint64
- func (x *ProposalByFilterRequest) GetOnlyActive() bool
- func (x *ProposalByFilterRequest) GetProposalIds() []string
- func (*ProposalByFilterRequest) ProtoMessage()
- func (x *ProposalByFilterRequest) ProtoReflect() protoreflect.Message
- func (x *ProposalByFilterRequest) Reset()
- func (x *ProposalByFilterRequest) String() string
- type ProposalByFilterResponse
- func (*ProposalByFilterResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ProposalByFilterResponse) GetProposals() []*ProposalInfo
- func (x *ProposalByFilterResponse) GetTotalCount() uint64
- func (*ProposalByFilterResponse) ProtoMessage()
- func (x *ProposalByFilterResponse) ProtoReflect() protoreflect.Message
- func (x *ProposalByFilterResponse) Reset()
- func (x *ProposalByFilterResponse) String() string
- type ProposalByIDRequest
- func (*ProposalByIDRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ProposalByIDRequest) GetProposalId() string
- func (*ProposalByIDRequest) ProtoMessage()
- func (x *ProposalByIDRequest) ProtoReflect() protoreflect.Message
- func (x *ProposalByIDRequest) Reset()
- func (x *ProposalByIDRequest) String() string
- type ProposalByIDResponse
- func (*ProposalByIDResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ProposalByIDResponse) GetProposal() *ProposalInfo
- func (*ProposalByIDResponse) ProtoMessage()
- func (x *ProposalByIDResponse) ProtoReflect() protoreflect.Message
- func (x *ProposalByIDResponse) Reset()
- func (x *ProposalByIDResponse) String() string
- type ProposalClient
- type ProposalInfo
- func (*ProposalInfo) Descriptor() ([]byte, []int)deprecated
- func (x *ProposalInfo) GetAuthor() string
- func (x *ProposalInfo) GetChoices() []string
- func (x *ProposalInfo) GetCreatedAt() *timestamppb.Timestamp
- func (x *ProposalInfo) GetDaoId() string
- func (x *ProposalInfo) GetId() string
- func (x *ProposalInfo) GetOriginalCreatedAt() *timestamppb.Timestamp
- func (x *ProposalInfo) GetPrivacy() string
- func (x *ProposalInfo) GetSpam() bool
- func (x *ProposalInfo) GetState() string
- func (x *ProposalInfo) GetTimeline() []*Timeline
- func (x *ProposalInfo) GetTitle() string
- func (x *ProposalInfo) GetType() string
- func (x *ProposalInfo) GetUpdatedAt() *timestamppb.Timestamp
- func (x *ProposalInfo) GetVotingEndedAt() *timestamppb.Timestamp
- func (x *ProposalInfo) GetVotingStartedAt() *timestamppb.Timestamp
- func (*ProposalInfo) ProtoMessage()
- func (x *ProposalInfo) ProtoReflect() protoreflect.Message
- func (x *ProposalInfo) Reset()
- func (x *ProposalInfo) String() string
- type ProposalServer
- type Timeline
- type UnimplementedDaoServer
- type UnimplementedProposalServer
- type UnsafeDaoServer
- type UnsafeProposalServer
Constants ¶
const ( Proposal_GetByID_FullMethodName = "/storage.Proposal/GetByID" Proposal_GetByFilter_FullMethodName = "/storage.Proposal/GetByFilter" )
const (
Dao_GetByID_FullMethodName = "/storage.Dao/GetByID"
)
Variables ¶
var Dao_ServiceDesc = grpc.ServiceDesc{ ServiceName: "storage.Dao", HandlerType: (*DaoServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GetByID", Handler: _Dao_GetByID_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "dao.proto", }
Dao_ServiceDesc is the grpc.ServiceDesc for Dao service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_dao_proto protoreflect.FileDescriptor
var File_proposal_proto protoreflect.FileDescriptor
var Proposal_ServiceDesc = grpc.ServiceDesc{ ServiceName: "storage.Proposal", HandlerType: (*ProposalServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GetByID", Handler: _Proposal_GetByID_Handler, }, { MethodName: "GetByFilter", Handler: _Proposal_GetByFilter_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "proposal.proto", }
Proposal_ServiceDesc is the grpc.ServiceDesc for Proposal service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterDaoServer ¶
func RegisterDaoServer(s grpc.ServiceRegistrar, srv DaoServer)
func RegisterProposalServer ¶
func RegisterProposalServer(s grpc.ServiceRegistrar, srv ProposalServer)
Types ¶
type DaoByIDRequest ¶
type DaoByIDRequest struct { DaoId string `protobuf:"bytes,1,opt,name=dao_id,json=daoId,proto3" json:"dao_id,omitempty"` // contains filtered or unexported fields }
func (*DaoByIDRequest) Descriptor
deprecated
func (*DaoByIDRequest) Descriptor() ([]byte, []int)
Deprecated: Use DaoByIDRequest.ProtoReflect.Descriptor instead.
func (*DaoByIDRequest) GetDaoId ¶
func (x *DaoByIDRequest) GetDaoId() string
func (*DaoByIDRequest) ProtoMessage ¶
func (*DaoByIDRequest) ProtoMessage()
func (*DaoByIDRequest) ProtoReflect ¶
func (x *DaoByIDRequest) ProtoReflect() protoreflect.Message
func (*DaoByIDRequest) Reset ¶
func (x *DaoByIDRequest) Reset()
func (*DaoByIDRequest) String ¶
func (x *DaoByIDRequest) String() string
type DaoByIDResponse ¶
type DaoByIDResponse struct { Dao *DaoInfo `protobuf:"bytes,1,opt,name=dao,proto3" json:"dao,omitempty"` // contains filtered or unexported fields }
func (*DaoByIDResponse) Descriptor
deprecated
func (*DaoByIDResponse) Descriptor() ([]byte, []int)
Deprecated: Use DaoByIDResponse.ProtoReflect.Descriptor instead.
func (*DaoByIDResponse) GetDao ¶
func (x *DaoByIDResponse) GetDao() *DaoInfo
func (*DaoByIDResponse) ProtoMessage ¶
func (*DaoByIDResponse) ProtoMessage()
func (*DaoByIDResponse) ProtoReflect ¶
func (x *DaoByIDResponse) ProtoReflect() protoreflect.Message
func (*DaoByIDResponse) Reset ¶
func (x *DaoByIDResponse) Reset()
func (*DaoByIDResponse) String ¶
func (x *DaoByIDResponse) String() string
type DaoClient ¶
type DaoClient interface {
GetByID(ctx context.Context, in *DaoByIDRequest, opts ...grpc.CallOption) (*DaoByIDResponse, error)
}
DaoClient is the client API for Dao 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.
func NewDaoClient ¶
func NewDaoClient(cc grpc.ClientConnInterface) DaoClient
type DaoInfo ¶
type DaoInfo struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` CreatedAt *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"` UpdatedAt *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"` Name string `protobuf:"bytes,4,opt,name=name,proto3" json:"name,omitempty"` Avatar string `protobuf:"bytes,5,opt,name=avatar,proto3" json:"avatar,omitempty"` Alias string `protobuf:"bytes,6,opt,name=alias,proto3" json:"alias,omitempty"` Verified bool `protobuf:"varint,7,opt,name=verified,proto3" json:"verified,omitempty"` PopularityIndex float64 `protobuf:"fixed64,8,opt,name=popularity_index,json=popularityIndex,proto3" json:"popularity_index,omitempty"` // contains filtered or unexported fields }
func (*DaoInfo) Descriptor
deprecated
func (*DaoInfo) GetCreatedAt ¶
func (x *DaoInfo) GetCreatedAt() *timestamppb.Timestamp
func (*DaoInfo) GetPopularityIndex ¶
func (*DaoInfo) GetUpdatedAt ¶
func (x *DaoInfo) GetUpdatedAt() *timestamppb.Timestamp
func (*DaoInfo) GetVerified ¶
func (*DaoInfo) ProtoMessage ¶
func (*DaoInfo) ProtoMessage()
func (*DaoInfo) ProtoReflect ¶
func (x *DaoInfo) ProtoReflect() protoreflect.Message
type DaoServer ¶
type DaoServer interface { GetByID(context.Context, *DaoByIDRequest) (*DaoByIDResponse, error) // contains filtered or unexported methods }
DaoServer is the server API for Dao service. All implementations must embed UnimplementedDaoServer for forward compatibility.
type ProposalByFilterRequest ¶
type ProposalByFilterRequest struct { Dao *string `protobuf:"bytes,1,opt,name=dao,proto3,oneof" json:"dao,omitempty"` Limit *uint64 `protobuf:"varint,2,opt,name=limit,proto3,oneof" json:"limit,omitempty"` Offset *uint64 `protobuf:"varint,3,opt,name=offset,proto3,oneof" json:"offset,omitempty"` ProposalIds []string `protobuf:"bytes,4,rep,name=proposal_ids,json=proposalIds,proto3" json:"proposal_ids,omitempty"` OnlyActive *bool `protobuf:"varint,5,opt,name=only_active,json=onlyActive,proto3,oneof" json:"only_active,omitempty"` // contains filtered or unexported fields }
func (*ProposalByFilterRequest) Descriptor
deprecated
func (*ProposalByFilterRequest) Descriptor() ([]byte, []int)
Deprecated: Use ProposalByFilterRequest.ProtoReflect.Descriptor instead.
func (*ProposalByFilterRequest) GetDao ¶
func (x *ProposalByFilterRequest) GetDao() string
func (*ProposalByFilterRequest) GetLimit ¶
func (x *ProposalByFilterRequest) GetLimit() uint64
func (*ProposalByFilterRequest) GetOffset ¶
func (x *ProposalByFilterRequest) GetOffset() uint64
func (*ProposalByFilterRequest) GetOnlyActive ¶
func (x *ProposalByFilterRequest) GetOnlyActive() bool
func (*ProposalByFilterRequest) GetProposalIds ¶
func (x *ProposalByFilterRequest) GetProposalIds() []string
func (*ProposalByFilterRequest) ProtoMessage ¶
func (*ProposalByFilterRequest) ProtoMessage()
func (*ProposalByFilterRequest) ProtoReflect ¶
func (x *ProposalByFilterRequest) ProtoReflect() protoreflect.Message
func (*ProposalByFilterRequest) Reset ¶
func (x *ProposalByFilterRequest) Reset()
func (*ProposalByFilterRequest) String ¶
func (x *ProposalByFilterRequest) String() string
type ProposalByFilterResponse ¶
type ProposalByFilterResponse struct { Proposals []*ProposalInfo `protobuf:"bytes,1,rep,name=proposals,proto3" json:"proposals,omitempty"` TotalCount uint64 `protobuf:"varint,2,opt,name=total_count,json=totalCount,proto3" json:"total_count,omitempty"` // contains filtered or unexported fields }
func (*ProposalByFilterResponse) Descriptor
deprecated
func (*ProposalByFilterResponse) Descriptor() ([]byte, []int)
Deprecated: Use ProposalByFilterResponse.ProtoReflect.Descriptor instead.
func (*ProposalByFilterResponse) GetProposals ¶
func (x *ProposalByFilterResponse) GetProposals() []*ProposalInfo
func (*ProposalByFilterResponse) GetTotalCount ¶
func (x *ProposalByFilterResponse) GetTotalCount() uint64
func (*ProposalByFilterResponse) ProtoMessage ¶
func (*ProposalByFilterResponse) ProtoMessage()
func (*ProposalByFilterResponse) ProtoReflect ¶
func (x *ProposalByFilterResponse) ProtoReflect() protoreflect.Message
func (*ProposalByFilterResponse) Reset ¶
func (x *ProposalByFilterResponse) Reset()
func (*ProposalByFilterResponse) String ¶
func (x *ProposalByFilterResponse) String() string
type ProposalByIDRequest ¶
type ProposalByIDRequest struct { ProposalId string `protobuf:"bytes,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"` // contains filtered or unexported fields }
func (*ProposalByIDRequest) Descriptor
deprecated
func (*ProposalByIDRequest) Descriptor() ([]byte, []int)
Deprecated: Use ProposalByIDRequest.ProtoReflect.Descriptor instead.
func (*ProposalByIDRequest) GetProposalId ¶
func (x *ProposalByIDRequest) GetProposalId() string
func (*ProposalByIDRequest) ProtoMessage ¶
func (*ProposalByIDRequest) ProtoMessage()
func (*ProposalByIDRequest) ProtoReflect ¶
func (x *ProposalByIDRequest) ProtoReflect() protoreflect.Message
func (*ProposalByIDRequest) Reset ¶
func (x *ProposalByIDRequest) Reset()
func (*ProposalByIDRequest) String ¶
func (x *ProposalByIDRequest) String() string
type ProposalByIDResponse ¶
type ProposalByIDResponse struct { Proposal *ProposalInfo `protobuf:"bytes,1,opt,name=proposal,proto3" json:"proposal,omitempty"` // contains filtered or unexported fields }
func (*ProposalByIDResponse) Descriptor
deprecated
func (*ProposalByIDResponse) Descriptor() ([]byte, []int)
Deprecated: Use ProposalByIDResponse.ProtoReflect.Descriptor instead.
func (*ProposalByIDResponse) GetProposal ¶
func (x *ProposalByIDResponse) GetProposal() *ProposalInfo
func (*ProposalByIDResponse) ProtoMessage ¶
func (*ProposalByIDResponse) ProtoMessage()
func (*ProposalByIDResponse) ProtoReflect ¶
func (x *ProposalByIDResponse) ProtoReflect() protoreflect.Message
func (*ProposalByIDResponse) Reset ¶
func (x *ProposalByIDResponse) Reset()
func (*ProposalByIDResponse) String ¶
func (x *ProposalByIDResponse) String() string
type ProposalClient ¶
type ProposalClient interface { GetByID(ctx context.Context, in *ProposalByIDRequest, opts ...grpc.CallOption) (*ProposalByIDResponse, error) GetByFilter(ctx context.Context, in *ProposalByFilterRequest, opts ...grpc.CallOption) (*ProposalByFilterResponse, error) }
ProposalClient is the client API for Proposal 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.
func NewProposalClient ¶
func NewProposalClient(cc grpc.ClientConnInterface) ProposalClient
type ProposalInfo ¶
type ProposalInfo struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` CreatedAt *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"` UpdatedAt *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"` Author string `protobuf:"bytes,4,opt,name=author,proto3" json:"author,omitempty"` DaoId string `protobuf:"bytes,5,opt,name=dao_id,json=daoId,proto3" json:"dao_id,omitempty"` Title string `protobuf:"bytes,7,opt,name=title,proto3" json:"title,omitempty"` State string `protobuf:"bytes,8,opt,name=state,proto3" json:"state,omitempty"` Type string `protobuf:"bytes,9,opt,name=type,proto3" json:"type,omitempty"` Privacy string `protobuf:"bytes,10,opt,name=privacy,proto3" json:"privacy,omitempty"` Spam bool `protobuf:"varint,11,opt,name=spam,proto3" json:"spam,omitempty"` Timeline []*Timeline `protobuf:"bytes,12,rep,name=timeline,proto3" json:"timeline,omitempty"` Choices []string `protobuf:"bytes,13,rep,name=choices,proto3" json:"choices,omitempty"` OriginalCreatedAt *timestamppb.Timestamp `protobuf:"bytes,14,opt,name=original_created_at,json=originalCreatedAt,proto3" json:"original_created_at,omitempty"` VotingStartedAt *timestamppb.Timestamp `protobuf:"bytes,15,opt,name=voting_started_at,json=votingStartedAt,proto3" json:"voting_started_at,omitempty"` VotingEndedAt *timestamppb.Timestamp `protobuf:"bytes,16,opt,name=voting_ended_at,json=votingEndedAt,proto3" json:"voting_ended_at,omitempty"` // contains filtered or unexported fields }
func (*ProposalInfo) Descriptor
deprecated
func (*ProposalInfo) Descriptor() ([]byte, []int)
Deprecated: Use ProposalInfo.ProtoReflect.Descriptor instead.
func (*ProposalInfo) GetAuthor ¶
func (x *ProposalInfo) GetAuthor() string
func (*ProposalInfo) GetChoices ¶
func (x *ProposalInfo) GetChoices() []string
func (*ProposalInfo) GetCreatedAt ¶
func (x *ProposalInfo) GetCreatedAt() *timestamppb.Timestamp
func (*ProposalInfo) GetDaoId ¶
func (x *ProposalInfo) GetDaoId() string
func (*ProposalInfo) GetId ¶
func (x *ProposalInfo) GetId() string
func (*ProposalInfo) GetOriginalCreatedAt ¶
func (x *ProposalInfo) GetOriginalCreatedAt() *timestamppb.Timestamp
func (*ProposalInfo) GetPrivacy ¶
func (x *ProposalInfo) GetPrivacy() string
func (*ProposalInfo) GetSpam ¶
func (x *ProposalInfo) GetSpam() bool
func (*ProposalInfo) GetState ¶
func (x *ProposalInfo) GetState() string
func (*ProposalInfo) GetTimeline ¶
func (x *ProposalInfo) GetTimeline() []*Timeline
func (*ProposalInfo) GetTitle ¶
func (x *ProposalInfo) GetTitle() string
func (*ProposalInfo) GetType ¶
func (x *ProposalInfo) GetType() string
func (*ProposalInfo) GetUpdatedAt ¶
func (x *ProposalInfo) GetUpdatedAt() *timestamppb.Timestamp
func (*ProposalInfo) GetVotingEndedAt ¶
func (x *ProposalInfo) GetVotingEndedAt() *timestamppb.Timestamp
func (*ProposalInfo) GetVotingStartedAt ¶
func (x *ProposalInfo) GetVotingStartedAt() *timestamppb.Timestamp
func (*ProposalInfo) ProtoMessage ¶
func (*ProposalInfo) ProtoMessage()
func (*ProposalInfo) ProtoReflect ¶
func (x *ProposalInfo) ProtoReflect() protoreflect.Message
func (*ProposalInfo) Reset ¶
func (x *ProposalInfo) Reset()
func (*ProposalInfo) String ¶
func (x *ProposalInfo) String() string
type ProposalServer ¶
type ProposalServer interface { GetByID(context.Context, *ProposalByIDRequest) (*ProposalByIDResponse, error) GetByFilter(context.Context, *ProposalByFilterRequest) (*ProposalByFilterResponse, error) // contains filtered or unexported methods }
ProposalServer is the server API for Proposal service. All implementations must embed UnimplementedProposalServer for forward compatibility.
type Timeline ¶
type Timeline struct { Action string `protobuf:"bytes,1,opt,name=action,proto3" json:"action,omitempty"` CreatedAt *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"` // contains filtered or unexported fields }
func (*Timeline) Descriptor
deprecated
func (*Timeline) GetCreatedAt ¶
func (x *Timeline) GetCreatedAt() *timestamppb.Timestamp
func (*Timeline) ProtoMessage ¶
func (*Timeline) ProtoMessage()
func (*Timeline) ProtoReflect ¶
func (x *Timeline) ProtoReflect() protoreflect.Message
type UnimplementedDaoServer ¶
type UnimplementedDaoServer struct{}
UnimplementedDaoServer must be embedded to have forward compatible implementations.
NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.
func (UnimplementedDaoServer) GetByID ¶
func (UnimplementedDaoServer) GetByID(context.Context, *DaoByIDRequest) (*DaoByIDResponse, error)
type UnimplementedProposalServer ¶
type UnimplementedProposalServer struct{}
UnimplementedProposalServer must be embedded to have forward compatible implementations.
NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.
func (UnimplementedProposalServer) GetByFilter ¶
func (UnimplementedProposalServer) GetByFilter(context.Context, *ProposalByFilterRequest) (*ProposalByFilterResponse, error)
func (UnimplementedProposalServer) GetByID ¶
func (UnimplementedProposalServer) GetByID(context.Context, *ProposalByIDRequest) (*ProposalByIDResponse, error)
type UnsafeDaoServer ¶
type UnsafeDaoServer interface {
// contains filtered or unexported methods
}
UnsafeDaoServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to DaoServer will result in compilation errors.
type UnsafeProposalServer ¶
type UnsafeProposalServer interface {
// contains filtered or unexported methods
}
UnsafeProposalServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ProposalServer will result in compilation errors.