Documentation ¶
Index ¶
- Variables
- func RegisterArticleServiceServer(s grpc.ServiceRegistrar, srv ArticleServiceServer)
- type Article
- func (*Article) Descriptor() ([]byte, []int)deprecated
- func (x *Article) GetAID() string
- func (x *Article) GetAbstract() string
- func (x *Article) GetArticleTags() string
- func (x *Article) GetAuthors() string
- func (x *Article) GetCategory() string
- func (x *Article) GetID() int64
- func (x *Article) GetImage() string
- func (x *Article) GetLanguage() string
- func (x *Article) GetText() string
- func (x *Article) GetTimestamp() int64
- func (x *Article) GetTitle() string
- func (x *Article) GetVideo() string
- func (*Article) ProtoMessage()
- func (x *Article) ProtoReflect() protoreflect.Message
- func (x *Article) Reset()
- func (x *Article) String() string
- type ArticleServiceClient
- type ArticleServiceServer
- type Articles
- type Category
- type Count
- type ID
- type IDs
- type InformationRequest
- type InformationResponse
- func (*InformationResponse) Descriptor() ([]byte, []int)deprecated
- func (x *InformationResponse) GetHost() string
- func (x *InformationResponse) GetIP() string
- func (*InformationResponse) ProtoMessage()
- func (x *InformationResponse) ProtoReflect() protoreflect.Message
- func (x *InformationResponse) Reset()
- func (x *InformationResponse) String() string
- type UnimplementedArticleServiceServer
- func (UnimplementedArticleServiceServer) GetArticlesByRegion(context.Context, *ID) (*Articles, error)
- func (UnimplementedArticleServiceServer) GetCategoryArticles(context.Context, *Category) (*Articles, error)
- func (UnimplementedArticleServiceServer) GetSingleArticle(context.Context, *ID) (*Article, error)
- func (UnimplementedArticleServiceServer) NewArticle(context.Context, *Article) (*ID, error)
- func (UnimplementedArticleServiceServer) NewArticles(context.Context, *Articles) (*IDs, error)
- func (UnimplementedArticleServiceServer) ServiceInformation(context.Context, *InformationRequest) (*InformationResponse, error)
- type UnsafeArticleServiceServer
Constants ¶
This section is empty.
Variables ¶
var File_pb_articles_proto protoreflect.FileDescriptor
Functions ¶
func RegisterArticleServiceServer ¶
func RegisterArticleServiceServer(s grpc.ServiceRegistrar, srv ArticleServiceServer)
Types ¶
type Article ¶
type Article struct { ID int64 `protobuf:"varint,1,opt,name=ID,proto3" json:"ID,omitempty"` Timestamp int64 `protobuf:"varint,2,opt,name=Timestamp,proto3" json:"Timestamp,omitempty"` AID string `protobuf:"bytes,3,opt,name=AID,proto3" json:"AID,omitempty"` Title string `protobuf:"bytes,4,opt,name=Title,proto3" json:"Title,omitempty"` Category string `protobuf:"bytes,5,opt,name=Category,proto3" json:"Category,omitempty"` Abstract string `protobuf:"bytes,6,opt,name=Abstract,proto3" json:"Abstract,omitempty"` ArticleTags string `protobuf:"bytes,7,opt,name=ArticleTags,proto3" json:"ArticleTags,omitempty"` Authors string `protobuf:"bytes,8,opt,name=Authors,proto3" json:"Authors,omitempty"` Language string `protobuf:"bytes,9,opt,name=Language,proto3" json:"Language,omitempty"` Text string `protobuf:"bytes,10,opt,name=Text,proto3" json:"Text,omitempty"` Image string `protobuf:"bytes,11,opt,name=Image,proto3" json:"Image,omitempty"` Video string `protobuf:"bytes,12,opt,name=Video,proto3" json:"Video,omitempty"` // contains filtered or unexported fields }
func (*Article) Descriptor
deprecated
func (*Article) GetAbstract ¶
func (*Article) GetArticleTags ¶
func (*Article) GetAuthors ¶
func (*Article) GetCategory ¶
func (*Article) GetLanguage ¶
func (*Article) GetTimestamp ¶
func (*Article) ProtoMessage ¶
func (*Article) ProtoMessage()
func (*Article) ProtoReflect ¶
func (x *Article) ProtoReflect() protoreflect.Message
type ArticleServiceClient ¶
type ArticleServiceClient interface { ServiceInformation(ctx context.Context, in *InformationRequest, opts ...grpc.CallOption) (*InformationResponse, error) GetSingleArticle(ctx context.Context, in *ID, opts ...grpc.CallOption) (*Article, error) GetCategoryArticles(ctx context.Context, in *Category, opts ...grpc.CallOption) (*Articles, error) GetArticlesByRegion(ctx context.Context, in *ID, opts ...grpc.CallOption) (*Articles, error) NewArticle(ctx context.Context, in *Article, opts ...grpc.CallOption) (*ID, error) NewArticles(ctx context.Context, in *Articles, opts ...grpc.CallOption) (*IDs, error) }
ArticleServiceClient is the client API for ArticleService 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 NewArticleServiceClient ¶
func NewArticleServiceClient(cc grpc.ClientConnInterface) ArticleServiceClient
type ArticleServiceServer ¶
type ArticleServiceServer interface { ServiceInformation(context.Context, *InformationRequest) (*InformationResponse, error) GetSingleArticle(context.Context, *ID) (*Article, error) GetCategoryArticles(context.Context, *Category) (*Articles, error) GetArticlesByRegion(context.Context, *ID) (*Articles, error) NewArticle(context.Context, *Article) (*ID, error) NewArticles(context.Context, *Articles) (*IDs, error) // contains filtered or unexported methods }
ArticleServiceServer is the server API for ArticleService service. All implementations must embed UnimplementedArticleServiceServer for forward compatibility
type Articles ¶
type Articles struct { Articles []*Article `protobuf:"bytes,1,rep,name=Articles,proto3" json:"Articles,omitempty"` // contains filtered or unexported fields }
func (*Articles) Descriptor
deprecated
func (*Articles) GetArticles ¶
func (*Articles) ProtoMessage ¶
func (*Articles) ProtoMessage()
func (*Articles) ProtoReflect ¶
func (x *Articles) ProtoReflect() protoreflect.Message
type Category ¶
type Category struct { Category string `protobuf:"bytes,1,opt,name=Category,proto3" json:"Category,omitempty"` // contains filtered or unexported fields }
func (*Category) Descriptor
deprecated
func (*Category) GetCategory ¶
func (*Category) ProtoMessage ¶
func (*Category) ProtoMessage()
func (*Category) ProtoReflect ¶
func (x *Category) ProtoReflect() protoreflect.Message
type Count ¶
type Count struct { Count int64 `protobuf:"varint,1,opt,name=Count,proto3" json:"Count,omitempty"` // contains filtered or unexported fields }
func (*Count) Descriptor
deprecated
func (*Count) ProtoMessage ¶
func (*Count) ProtoMessage()
func (*Count) ProtoReflect ¶
func (x *Count) ProtoReflect() protoreflect.Message
type ID ¶
type ID struct { ID int64 `protobuf:"varint,1,opt,name=ID,proto3" json:"ID,omitempty"` // contains filtered or unexported fields }
func (*ID) Descriptor
deprecated
func (*ID) ProtoMessage ¶
func (*ID) ProtoMessage()
func (*ID) ProtoReflect ¶
func (x *ID) ProtoReflect() protoreflect.Message
type IDs ¶
type IDs struct { IDs []*ID `protobuf:"bytes,1,rep,name=IDs,proto3" json:"IDs,omitempty"` // contains filtered or unexported fields }
func (*IDs) Descriptor
deprecated
func (*IDs) ProtoMessage ¶
func (*IDs) ProtoMessage()
func (*IDs) ProtoReflect ¶
func (x *IDs) ProtoReflect() protoreflect.Message
type InformationRequest ¶
type InformationRequest struct {
// contains filtered or unexported fields
}
func (*InformationRequest) Descriptor
deprecated
func (*InformationRequest) Descriptor() ([]byte, []int)
Deprecated: Use InformationRequest.ProtoReflect.Descriptor instead.
func (*InformationRequest) ProtoMessage ¶
func (*InformationRequest) ProtoMessage()
func (*InformationRequest) ProtoReflect ¶
func (x *InformationRequest) ProtoReflect() protoreflect.Message
func (*InformationRequest) Reset ¶
func (x *InformationRequest) Reset()
func (*InformationRequest) String ¶
func (x *InformationRequest) String() string
type InformationResponse ¶
type InformationResponse struct { IP string `protobuf:"bytes,1,opt,name=IP,proto3" json:"IP,omitempty"` Host string `protobuf:"bytes,2,opt,name=Host,proto3" json:"Host,omitempty"` // contains filtered or unexported fields }
func (*InformationResponse) Descriptor
deprecated
func (*InformationResponse) Descriptor() ([]byte, []int)
Deprecated: Use InformationResponse.ProtoReflect.Descriptor instead.
func (*InformationResponse) GetHost ¶
func (x *InformationResponse) GetHost() string
func (*InformationResponse) GetIP ¶
func (x *InformationResponse) GetIP() string
func (*InformationResponse) ProtoMessage ¶
func (*InformationResponse) ProtoMessage()
func (*InformationResponse) ProtoReflect ¶
func (x *InformationResponse) ProtoReflect() protoreflect.Message
func (*InformationResponse) Reset ¶
func (x *InformationResponse) Reset()
func (*InformationResponse) String ¶
func (x *InformationResponse) String() string
type UnimplementedArticleServiceServer ¶
type UnimplementedArticleServiceServer struct { }
UnimplementedArticleServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedArticleServiceServer) GetArticlesByRegion ¶
func (UnimplementedArticleServiceServer) GetCategoryArticles ¶
func (UnimplementedArticleServiceServer) GetSingleArticle ¶
func (UnimplementedArticleServiceServer) NewArticle ¶
func (UnimplementedArticleServiceServer) NewArticles ¶
func (UnimplementedArticleServiceServer) ServiceInformation ¶
func (UnimplementedArticleServiceServer) ServiceInformation(context.Context, *InformationRequest) (*InformationResponse, error)
type UnsafeArticleServiceServer ¶
type UnsafeArticleServiceServer interface {
// contains filtered or unexported methods
}
UnsafeArticleServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ArticleServiceServer will result in compilation errors.