Documentation ¶
Overview ¶
Package article is a reverse proxy.
It translates gRPC into RESTful JSON APIs.
Index ¶
- Variables
- func RegisterArticleHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
- func RegisterArticleHandlerClient(ctx context.Context, mux *runtime.ServeMux, client ArticleClient) error
- func RegisterArticleHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, ...) (err error)
- func RegisterArticleHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ArticleServer) error
- func RegisterArticleServer(s grpc.ServiceRegistrar, srv ArticleServer)
- type ArticleClient
- type ArticleInfo
- func (*ArticleInfo) Descriptor() ([]byte, []int)deprecated
- func (x *ArticleInfo) GetArticle() string
- func (x *ArticleInfo) GetAttachments() []string
- func (x *ArticleInfo) GetAudience() []int64
- func (x *ArticleInfo) GetBto() []string
- func (x *ArticleInfo) GetCc() []string
- func (x *ArticleInfo) GetCreateAt() string
- func (x *ArticleInfo) GetId() int64
- func (x *ArticleInfo) GetNsfw() bool
- func (x *ArticleInfo) GetSummary() string
- func (x *ArticleInfo) GetTags() []string
- func (x *ArticleInfo) GetTitle() string
- func (x *ArticleInfo) GetTo() []string
- func (x *ArticleInfo) GetUpdateAt() string
- func (x *ArticleInfo) GetVisibility() int64
- func (*ArticleInfo) ProtoMessage()
- func (x *ArticleInfo) ProtoReflect() protoreflect.Message
- func (x *ArticleInfo) Reset()
- func (x *ArticleInfo) String() string
- type ArticleServer
- type Attachments
- func (*Attachments) Descriptor() ([]byte, []int)deprecated
- func (x *Attachments) GetBlurhash() string
- func (x *Attachments) GetHeight() int64
- func (x *Attachments) GetMediaType() string
- func (x *Attachments) GetName() string
- func (x *Attachments) GetType() string
- func (x *Attachments) GetUrl() string
- func (x *Attachments) GetWidth() int64
- func (*Attachments) ProtoMessage()
- func (x *Attachments) ProtoReflect() protoreflect.Message
- func (x *Attachments) Reset()
- func (x *Attachments) String() string
- type CreateRequest
- func (*CreateRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CreateRequest) GetArticle() string
- func (x *CreateRequest) GetAttachment() []*Attachments
- func (x *CreateRequest) GetAudience() []int64
- func (x *CreateRequest) GetBto() []string
- func (x *CreateRequest) GetCc() []string
- func (x *CreateRequest) GetNsfw() bool
- func (x *CreateRequest) GetSummary() string
- func (x *CreateRequest) GetTags() []string
- func (x *CreateRequest) GetTitle() string
- func (x *CreateRequest) GetTo() []string
- func (x *CreateRequest) GetVisibility() int64
- func (*CreateRequest) ProtoMessage()
- func (x *CreateRequest) ProtoReflect() protoreflect.Message
- func (x *CreateRequest) Reset()
- func (x *CreateRequest) String() string
- type CreateResponse
- func (*CreateResponse) Descriptor() ([]byte, []int)deprecated
- func (x *CreateResponse) GetCode() string
- func (x *CreateResponse) GetFailures() []string
- func (x *CreateResponse) GetStatus() string
- func (x *CreateResponse) GetSuccesses() []string
- func (*CreateResponse) ProtoMessage()
- func (x *CreateResponse) ProtoReflect() protoreflect.Message
- func (x *CreateResponse) Reset()
- func (x *CreateResponse) String() string
- type DeleteArticlesRequest
- func (*DeleteArticlesRequest) Descriptor() ([]byte, []int)deprecated
- func (x *DeleteArticlesRequest) GetAccountId() int64
- func (*DeleteArticlesRequest) ProtoMessage()
- func (x *DeleteArticlesRequest) ProtoReflect() protoreflect.Message
- func (x *DeleteArticlesRequest) Reset()
- func (x *DeleteArticlesRequest) String() string
- type DeleteArticlesResponse
- func (*DeleteArticlesResponse) Descriptor() ([]byte, []int)deprecated
- func (x *DeleteArticlesResponse) GetCode() string
- func (x *DeleteArticlesResponse) GetStatus() string
- func (*DeleteArticlesResponse) ProtoMessage()
- func (x *DeleteArticlesResponse) ProtoReflect() protoreflect.Message
- func (x *DeleteArticlesResponse) Reset()
- func (x *DeleteArticlesResponse) String() string
- type DeleteRequest
- type DeleteResponse
- func (*DeleteResponse) Descriptor() ([]byte, []int)deprecated
- func (x *DeleteResponse) GetCode() string
- func (x *DeleteResponse) GetStatus() string
- func (*DeleteResponse) ProtoMessage()
- func (x *DeleteResponse) ProtoReflect() protoreflect.Message
- func (x *DeleteResponse) Reset()
- func (x *DeleteResponse) String() string
- type GetArticlesRequest
- func (*GetArticlesRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetArticlesRequest) GetAccountId() int64
- func (*GetArticlesRequest) ProtoMessage()
- func (x *GetArticlesRequest) ProtoReflect() protoreflect.Message
- func (x *GetArticlesRequest) Reset()
- func (x *GetArticlesRequest) String() string
- type GetArticlesResponse
- func (*GetArticlesResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetArticlesResponse) GetArticles() []*ArticleInfo
- func (x *GetArticlesResponse) GetCode() string
- func (*GetArticlesResponse) ProtoMessage()
- func (x *GetArticlesResponse) ProtoReflect() protoreflect.Message
- func (x *GetArticlesResponse) Reset()
- func (x *GetArticlesResponse) String() string
- type GetRequest
- type GetResponse
- func (*GetResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetResponse) GetActor() *actor.ActorData
- func (x *GetResponse) GetArticle() *ArticleInfo
- func (x *GetResponse) GetCode() string
- func (*GetResponse) ProtoMessage()
- func (x *GetResponse) ProtoReflect() protoreflect.Message
- func (x *GetResponse) Reset()
- func (x *GetResponse) String() string
- type UnimplementedArticleServer
- func (UnimplementedArticleServer) Create(context.Context, *CreateRequest) (*CreateResponse, error)
- func (UnimplementedArticleServer) Delete(context.Context, *DeleteRequest) (*DeleteResponse, error)
- func (UnimplementedArticleServer) DeleteArticles(context.Context, *DeleteArticlesRequest) (*DeleteArticlesResponse, error)
- func (UnimplementedArticleServer) Get(context.Context, *GetRequest) (*GetResponse, error)
- func (UnimplementedArticleServer) GetArticles(context.Context, *emptypb.Empty) (*GetArticlesResponse, error)
- func (UnimplementedArticleServer) Update(context.Context, *UpdateRequest) (*UpdateResponse, error)
- type UnsafeArticleServer
- type UpdateRequest
- func (*UpdateRequest) Descriptor() ([]byte, []int)deprecated
- func (x *UpdateRequest) GetArticle() string
- func (x *UpdateRequest) GetAttachments() []string
- func (x *UpdateRequest) GetId() int64
- func (x *UpdateRequest) GetSummary() string
- func (x *UpdateRequest) GetTags() []string
- func (x *UpdateRequest) GetTitle() string
- func (*UpdateRequest) ProtoMessage()
- func (x *UpdateRequest) ProtoReflect() protoreflect.Message
- func (x *UpdateRequest) Reset()
- func (x *UpdateRequest) String() string
- type UpdateResponse
- func (*UpdateResponse) Descriptor() ([]byte, []int)deprecated
- func (x *UpdateResponse) GetCode() string
- func (x *UpdateResponse) GetStatus() string
- func (*UpdateResponse) ProtoMessage()
- func (x *UpdateResponse) ProtoReflect() protoreflect.Message
- func (x *UpdateResponse) Reset()
- func (x *UpdateResponse) String() string
Constants ¶
This section is empty.
Variables ¶
var Article_ServiceDesc = grpc.ServiceDesc{ ServiceName: "hvx.api.v1alpha1.article.proto.Article", HandlerType: (*ArticleServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Create", Handler: _Article_Create_Handler, }, { MethodName: "Get", Handler: _Article_Get_Handler, }, { MethodName: "GetArticles", Handler: _Article_GetArticles_Handler, }, { MethodName: "Update", Handler: _Article_Update_Handler, }, { MethodName: "Delete", Handler: _Article_Delete_Handler, }, { MethodName: "DeleteArticles", Handler: _Article_DeleteArticles_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "proto/v1alpha1/article/article.proto", }
Article_ServiceDesc is the grpc.ServiceDesc for Article service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_proto_v1alpha1_article_article_proto protoreflect.FileDescriptor
Functions ¶
func RegisterArticleHandler ¶
func RegisterArticleHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
RegisterArticleHandler registers the http handlers for service Article to "mux". The handlers forward requests to the grpc endpoint over "conn".
func RegisterArticleHandlerClient ¶
func RegisterArticleHandlerClient(ctx context.Context, mux *runtime.ServeMux, client ArticleClient) error
RegisterArticleHandlerClient registers the http handlers for service Article to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "ArticleClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "ArticleClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "ArticleClient" to call the correct interceptors.
func RegisterArticleHandlerFromEndpoint ¶
func RegisterArticleHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)
RegisterArticleHandlerFromEndpoint is same as RegisterArticleHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.
func RegisterArticleHandlerServer ¶
func RegisterArticleHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ArticleServer) error
RegisterArticleHandlerServer registers the http handlers for service Article to "mux". UnaryRPC :call ArticleServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterArticleHandlerFromEndpoint instead.
func RegisterArticleServer ¶
func RegisterArticleServer(s grpc.ServiceRegistrar, srv ArticleServer)
Types ¶
type ArticleClient ¶
type ArticleClient interface { // Create article or status. Create(ctx context.Context, in *CreateRequest, opts ...grpc.CallOption) (*CreateResponse, error) // Get the content of an article or status by its article ID. Get(ctx context.Context, in *GetRequest, opts ...grpc.CallOption) (*GetResponse, error) // GetArticles Get all posts or statuses published under this account by account ID. GetArticles(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*GetArticlesResponse, error) // Update Edit article or status content. Update(ctx context.Context, in *UpdateRequest, opts ...grpc.CallOption) (*UpdateResponse, error) // Delete a post or status by post or status ID. Delete(ctx context.Context, in *DeleteRequest, opts ...grpc.CallOption) (*DeleteResponse, error) // DeleteArticles Delete all articles DeleteArticles(ctx context.Context, in *DeleteArticlesRequest, opts ...grpc.CallOption) (*DeleteArticlesResponse, error) }
ArticleClient is the client API for Article 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 NewArticleClient ¶
func NewArticleClient(cc grpc.ClientConnInterface) ArticleClient
type ArticleInfo ¶
type ArticleInfo struct { Title string `protobuf:"bytes,1,opt,name=title,proto3" json:"title,omitempty"` Summary string `protobuf:"bytes,2,opt,name=summary,proto3" json:"summary,omitempty"` Article string `protobuf:"bytes,3,opt,name=article,proto3" json:"article,omitempty"` Tags []string `protobuf:"bytes,4,rep,name=tags,proto3" json:"tags,omitempty"` Nsfw bool `protobuf:"varint,5,opt,name=nsfw,proto3" json:"nsfw,omitempty"` To []string `protobuf:"bytes,7,rep,name=to,proto3" json:"to,omitempty"` Cc []string `protobuf:"bytes,8,rep,name=cc,proto3" json:"cc,omitempty"` Bto []string `protobuf:"bytes,9,rep,name=bto,proto3" json:"bto,omitempty"` Audience []int64 `protobuf:"varint,10,rep,packed,name=audience,proto3" json:"audience,omitempty"` Attachments []string `protobuf:"bytes,11,rep,name=attachments,proto3" json:"attachments,omitempty"` Visibility int64 `protobuf:"varint,12,opt,name=visibility,proto3" json:"visibility,omitempty"` Id int64 `protobuf:"varint,13,opt,name=id,proto3" json:"id,omitempty"` CreateAt string `protobuf:"bytes,14,opt,name=createAt,proto3" json:"createAt,omitempty"` UpdateAt string `protobuf:"bytes,15,opt,name=updateAt,proto3" json:"updateAt,omitempty"` // contains filtered or unexported fields }
func (*ArticleInfo) Descriptor
deprecated
func (*ArticleInfo) Descriptor() ([]byte, []int)
Deprecated: Use ArticleInfo.ProtoReflect.Descriptor instead.
func (*ArticleInfo) GetArticle ¶
func (x *ArticleInfo) GetArticle() string
func (*ArticleInfo) GetAttachments ¶
func (x *ArticleInfo) GetAttachments() []string
func (*ArticleInfo) GetAudience ¶
func (x *ArticleInfo) GetAudience() []int64
func (*ArticleInfo) GetBto ¶
func (x *ArticleInfo) GetBto() []string
func (*ArticleInfo) GetCc ¶
func (x *ArticleInfo) GetCc() []string
func (*ArticleInfo) GetCreateAt ¶
func (x *ArticleInfo) GetCreateAt() string
func (*ArticleInfo) GetId ¶
func (x *ArticleInfo) GetId() int64
func (*ArticleInfo) GetNsfw ¶
func (x *ArticleInfo) GetNsfw() bool
func (*ArticleInfo) GetSummary ¶
func (x *ArticleInfo) GetSummary() string
func (*ArticleInfo) GetTags ¶
func (x *ArticleInfo) GetTags() []string
func (*ArticleInfo) GetTitle ¶
func (x *ArticleInfo) GetTitle() string
func (*ArticleInfo) GetTo ¶
func (x *ArticleInfo) GetTo() []string
func (*ArticleInfo) GetUpdateAt ¶
func (x *ArticleInfo) GetUpdateAt() string
func (*ArticleInfo) GetVisibility ¶
func (x *ArticleInfo) GetVisibility() int64
func (*ArticleInfo) ProtoMessage ¶
func (*ArticleInfo) ProtoMessage()
func (*ArticleInfo) ProtoReflect ¶
func (x *ArticleInfo) ProtoReflect() protoreflect.Message
func (*ArticleInfo) Reset ¶
func (x *ArticleInfo) Reset()
func (*ArticleInfo) String ¶
func (x *ArticleInfo) String() string
type ArticleServer ¶
type ArticleServer interface { // Create article or status. Create(context.Context, *CreateRequest) (*CreateResponse, error) // Get the content of an article or status by its article ID. Get(context.Context, *GetRequest) (*GetResponse, error) // GetArticles Get all posts or statuses published under this account by account ID. GetArticles(context.Context, *emptypb.Empty) (*GetArticlesResponse, error) // Update Edit article or status content. Update(context.Context, *UpdateRequest) (*UpdateResponse, error) // Delete a post or status by post or status ID. Delete(context.Context, *DeleteRequest) (*DeleteResponse, error) // DeleteArticles Delete all articles DeleteArticles(context.Context, *DeleteArticlesRequest) (*DeleteArticlesResponse, error) }
ArticleServer is the server API for Article service. All implementations should embed UnimplementedArticleServer for forward compatibility
type Attachments ¶
type Attachments struct { Type string `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"` MediaType string `protobuf:"bytes,2,opt,name=mediaType,proto3" json:"mediaType,omitempty"` Url string `protobuf:"bytes,3,opt,name=url,proto3" json:"url,omitempty"` Name string `protobuf:"bytes,4,opt,name=name,proto3" json:"name,omitempty"` Blurhash string `protobuf:"bytes,5,opt,name=blurhash,proto3" json:"blurhash,omitempty"` Width int64 `protobuf:"varint,6,opt,name=width,proto3" json:"width,omitempty"` Height int64 `protobuf:"varint,7,opt,name=height,proto3" json:"height,omitempty"` // contains filtered or unexported fields }
func (*Attachments) Descriptor
deprecated
func (*Attachments) Descriptor() ([]byte, []int)
Deprecated: Use Attachments.ProtoReflect.Descriptor instead.
func (*Attachments) GetBlurhash ¶
func (x *Attachments) GetBlurhash() string
func (*Attachments) GetHeight ¶
func (x *Attachments) GetHeight() int64
func (*Attachments) GetMediaType ¶
func (x *Attachments) GetMediaType() string
func (*Attachments) GetName ¶
func (x *Attachments) GetName() string
func (*Attachments) GetType ¶
func (x *Attachments) GetType() string
func (*Attachments) GetUrl ¶
func (x *Attachments) GetUrl() string
func (*Attachments) GetWidth ¶
func (x *Attachments) GetWidth() int64
func (*Attachments) ProtoMessage ¶
func (*Attachments) ProtoMessage()
func (*Attachments) ProtoReflect ¶
func (x *Attachments) ProtoReflect() protoreflect.Message
func (*Attachments) Reset ¶
func (x *Attachments) Reset()
func (*Attachments) String ¶
func (x *Attachments) String() string
type CreateRequest ¶
type CreateRequest struct { // title is Article title, if the post is a status (status & Activitypub Note) then this field should be empty. Title string `protobuf:"bytes,1,opt,name=title,proto3" json:"title,omitempty"` // summary If you are creating an article, you can use this field to add a summary of the article. Summary string `protobuf:"bytes,2,opt,name=summary,proto3" json:"summary,omitempty"` // article Both article and status should use this field to store the body. Article string `protobuf:"bytes,3,opt,name=article,proto3" json:"article,omitempty"` Tags []string `protobuf:"bytes,4,rep,name=tags,proto3" json:"tags,omitempty"` Nsfw bool `protobuf:"varint,5,opt,name=nsfw,proto3" json:"nsfw,omitempty"` To []string `protobuf:"bytes,7,rep,name=to,proto3" json:"to,omitempty"` Cc []string `protobuf:"bytes,8,rep,name=cc,proto3" json:"cc,omitempty"` Bto []string `protobuf:"bytes,9,rep,name=bto,proto3" json:"bto,omitempty"` Audience []int64 `protobuf:"varint,10,rep,packed,name=audience,proto3" json:"audience,omitempty"` Attachment []*Attachments `protobuf:"bytes,11,rep,name=attachment,proto3" json:"attachment,omitempty"` Visibility int64 `protobuf:"varint,12,opt,name=visibility,proto3" json:"visibility,omitempty"` // contains filtered or unexported fields }
func (*CreateRequest) Descriptor
deprecated
func (*CreateRequest) Descriptor() ([]byte, []int)
Deprecated: Use CreateRequest.ProtoReflect.Descriptor instead.
func (*CreateRequest) GetArticle ¶
func (x *CreateRequest) GetArticle() string
func (*CreateRequest) GetAttachment ¶
func (x *CreateRequest) GetAttachment() []*Attachments
func (*CreateRequest) GetAudience ¶
func (x *CreateRequest) GetAudience() []int64
func (*CreateRequest) GetBto ¶
func (x *CreateRequest) GetBto() []string
func (*CreateRequest) GetCc ¶
func (x *CreateRequest) GetCc() []string
func (*CreateRequest) GetNsfw ¶
func (x *CreateRequest) GetNsfw() bool
func (*CreateRequest) GetSummary ¶
func (x *CreateRequest) GetSummary() string
func (*CreateRequest) GetTags ¶
func (x *CreateRequest) GetTags() []string
func (*CreateRequest) GetTitle ¶
func (x *CreateRequest) GetTitle() string
func (*CreateRequest) GetTo ¶
func (x *CreateRequest) GetTo() []string
func (*CreateRequest) GetVisibility ¶
func (x *CreateRequest) GetVisibility() int64
func (*CreateRequest) ProtoMessage ¶
func (*CreateRequest) ProtoMessage()
func (*CreateRequest) ProtoReflect ¶
func (x *CreateRequest) ProtoReflect() protoreflect.Message
func (*CreateRequest) Reset ¶
func (x *CreateRequest) Reset()
func (*CreateRequest) String ¶
func (x *CreateRequest) String() string
type CreateResponse ¶
type CreateResponse struct { Code string `protobuf:"bytes,1,opt,name=code,proto3" json:"code,omitempty"` Status string `protobuf:"bytes,2,opt,name=status,proto3" json:"status,omitempty"` Successes []string `protobuf:"bytes,3,rep,name=successes,proto3" json:"successes,omitempty"` Failures []string `protobuf:"bytes,4,rep,name=failures,proto3" json:"failures,omitempty"` // contains filtered or unexported fields }
func (*CreateResponse) Descriptor
deprecated
func (*CreateResponse) Descriptor() ([]byte, []int)
Deprecated: Use CreateResponse.ProtoReflect.Descriptor instead.
func (*CreateResponse) GetCode ¶
func (x *CreateResponse) GetCode() string
func (*CreateResponse) GetFailures ¶
func (x *CreateResponse) GetFailures() []string
func (*CreateResponse) GetStatus ¶
func (x *CreateResponse) GetStatus() string
func (*CreateResponse) GetSuccesses ¶
func (x *CreateResponse) GetSuccesses() []string
func (*CreateResponse) ProtoMessage ¶
func (*CreateResponse) ProtoMessage()
func (*CreateResponse) ProtoReflect ¶
func (x *CreateResponse) ProtoReflect() protoreflect.Message
func (*CreateResponse) Reset ¶
func (x *CreateResponse) Reset()
func (*CreateResponse) String ¶
func (x *CreateResponse) String() string
type DeleteArticlesRequest ¶
type DeleteArticlesRequest struct { AccountId int64 `protobuf:"varint,1,opt,name=accountId,proto3" json:"accountId,omitempty"` // contains filtered or unexported fields }
func (*DeleteArticlesRequest) Descriptor
deprecated
func (*DeleteArticlesRequest) Descriptor() ([]byte, []int)
Deprecated: Use DeleteArticlesRequest.ProtoReflect.Descriptor instead.
func (*DeleteArticlesRequest) GetAccountId ¶
func (x *DeleteArticlesRequest) GetAccountId() int64
func (*DeleteArticlesRequest) ProtoMessage ¶
func (*DeleteArticlesRequest) ProtoMessage()
func (*DeleteArticlesRequest) ProtoReflect ¶
func (x *DeleteArticlesRequest) ProtoReflect() protoreflect.Message
func (*DeleteArticlesRequest) Reset ¶
func (x *DeleteArticlesRequest) Reset()
func (*DeleteArticlesRequest) String ¶
func (x *DeleteArticlesRequest) String() string
type DeleteArticlesResponse ¶
type DeleteArticlesResponse struct { Code string `protobuf:"bytes,1,opt,name=code,proto3" json:"code,omitempty"` Status string `protobuf:"bytes,2,opt,name=status,proto3" json:"status,omitempty"` // contains filtered or unexported fields }
func (*DeleteArticlesResponse) Descriptor
deprecated
func (*DeleteArticlesResponse) Descriptor() ([]byte, []int)
Deprecated: Use DeleteArticlesResponse.ProtoReflect.Descriptor instead.
func (*DeleteArticlesResponse) GetCode ¶
func (x *DeleteArticlesResponse) GetCode() string
func (*DeleteArticlesResponse) GetStatus ¶
func (x *DeleteArticlesResponse) GetStatus() string
func (*DeleteArticlesResponse) ProtoMessage ¶
func (*DeleteArticlesResponse) ProtoMessage()
func (*DeleteArticlesResponse) ProtoReflect ¶
func (x *DeleteArticlesResponse) ProtoReflect() protoreflect.Message
func (*DeleteArticlesResponse) Reset ¶
func (x *DeleteArticlesResponse) Reset()
func (*DeleteArticlesResponse) String ¶
func (x *DeleteArticlesResponse) String() string
type DeleteRequest ¶
type DeleteRequest struct { ArticleId string `protobuf:"bytes,1,opt,name=articleId,proto3" json:"articleId,omitempty"` // contains filtered or unexported fields }
func (*DeleteRequest) Descriptor
deprecated
func (*DeleteRequest) Descriptor() ([]byte, []int)
Deprecated: Use DeleteRequest.ProtoReflect.Descriptor instead.
func (*DeleteRequest) GetArticleId ¶
func (x *DeleteRequest) GetArticleId() string
func (*DeleteRequest) ProtoMessage ¶
func (*DeleteRequest) ProtoMessage()
func (*DeleteRequest) ProtoReflect ¶
func (x *DeleteRequest) ProtoReflect() protoreflect.Message
func (*DeleteRequest) Reset ¶
func (x *DeleteRequest) Reset()
func (*DeleteRequest) String ¶
func (x *DeleteRequest) String() string
type DeleteResponse ¶
type DeleteResponse struct { Code string `protobuf:"bytes,1,opt,name=code,proto3" json:"code,omitempty"` Status string `protobuf:"bytes,2,opt,name=status,proto3" json:"status,omitempty"` // contains filtered or unexported fields }
func (*DeleteResponse) Descriptor
deprecated
func (*DeleteResponse) Descriptor() ([]byte, []int)
Deprecated: Use DeleteResponse.ProtoReflect.Descriptor instead.
func (*DeleteResponse) GetCode ¶
func (x *DeleteResponse) GetCode() string
func (*DeleteResponse) GetStatus ¶
func (x *DeleteResponse) GetStatus() string
func (*DeleteResponse) ProtoMessage ¶
func (*DeleteResponse) ProtoMessage()
func (*DeleteResponse) ProtoReflect ¶
func (x *DeleteResponse) ProtoReflect() protoreflect.Message
func (*DeleteResponse) Reset ¶
func (x *DeleteResponse) Reset()
func (*DeleteResponse) String ¶
func (x *DeleteResponse) String() string
type GetArticlesRequest ¶
type GetArticlesRequest struct { AccountId int64 `protobuf:"varint,1,opt,name=accountId,proto3" json:"accountId,omitempty"` // contains filtered or unexported fields }
func (*GetArticlesRequest) Descriptor
deprecated
func (*GetArticlesRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetArticlesRequest.ProtoReflect.Descriptor instead.
func (*GetArticlesRequest) GetAccountId ¶
func (x *GetArticlesRequest) GetAccountId() int64
func (*GetArticlesRequest) ProtoMessage ¶
func (*GetArticlesRequest) ProtoMessage()
func (*GetArticlesRequest) ProtoReflect ¶
func (x *GetArticlesRequest) ProtoReflect() protoreflect.Message
func (*GetArticlesRequest) Reset ¶
func (x *GetArticlesRequest) Reset()
func (*GetArticlesRequest) String ¶
func (x *GetArticlesRequest) String() string
type GetArticlesResponse ¶
type GetArticlesResponse struct { Code string `protobuf:"bytes,1,opt,name=code,proto3" json:"code,omitempty"` Articles []*ArticleInfo `protobuf:"bytes,2,rep,name=articles,proto3" json:"articles,omitempty"` // contains filtered or unexported fields }
func (*GetArticlesResponse) Descriptor
deprecated
func (*GetArticlesResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetArticlesResponse.ProtoReflect.Descriptor instead.
func (*GetArticlesResponse) GetArticles ¶
func (x *GetArticlesResponse) GetArticles() []*ArticleInfo
func (*GetArticlesResponse) GetCode ¶
func (x *GetArticlesResponse) GetCode() string
func (*GetArticlesResponse) ProtoMessage ¶
func (*GetArticlesResponse) ProtoMessage()
func (*GetArticlesResponse) ProtoReflect ¶
func (x *GetArticlesResponse) ProtoReflect() protoreflect.Message
func (*GetArticlesResponse) Reset ¶
func (x *GetArticlesResponse) Reset()
func (*GetArticlesResponse) String ¶
func (x *GetArticlesResponse) String() string
type GetRequest ¶
type GetRequest struct { ArticleId string `protobuf:"bytes,1,opt,name=articleId,proto3" json:"articleId,omitempty"` // contains filtered or unexported fields }
func (*GetRequest) Descriptor
deprecated
func (*GetRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetRequest.ProtoReflect.Descriptor instead.
func (*GetRequest) GetArticleId ¶
func (x *GetRequest) GetArticleId() string
func (*GetRequest) ProtoMessage ¶
func (*GetRequest) ProtoMessage()
func (*GetRequest) ProtoReflect ¶
func (x *GetRequest) ProtoReflect() protoreflect.Message
func (*GetRequest) Reset ¶
func (x *GetRequest) Reset()
func (*GetRequest) String ¶
func (x *GetRequest) String() string
type GetResponse ¶
type GetResponse struct { Code string `protobuf:"bytes,1,opt,name=code,proto3" json:"code,omitempty"` Actor *actor.ActorData `protobuf:"bytes,2,opt,name=actor,proto3" json:"actor,omitempty"` Article *ArticleInfo `protobuf:"bytes,3,opt,name=article,proto3" json:"article,omitempty"` // contains filtered or unexported fields }
func (*GetResponse) Descriptor
deprecated
func (*GetResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetResponse.ProtoReflect.Descriptor instead.
func (*GetResponse) GetActor ¶
func (x *GetResponse) GetActor() *actor.ActorData
func (*GetResponse) GetArticle ¶
func (x *GetResponse) GetArticle() *ArticleInfo
func (*GetResponse) GetCode ¶
func (x *GetResponse) GetCode() string
func (*GetResponse) ProtoMessage ¶
func (*GetResponse) ProtoMessage()
func (*GetResponse) ProtoReflect ¶
func (x *GetResponse) ProtoReflect() protoreflect.Message
func (*GetResponse) Reset ¶
func (x *GetResponse) Reset()
func (*GetResponse) String ¶
func (x *GetResponse) String() string
type UnimplementedArticleServer ¶
type UnimplementedArticleServer struct { }
UnimplementedArticleServer should be embedded to have forward compatible implementations.
func (UnimplementedArticleServer) Create ¶
func (UnimplementedArticleServer) Create(context.Context, *CreateRequest) (*CreateResponse, error)
func (UnimplementedArticleServer) Delete ¶
func (UnimplementedArticleServer) Delete(context.Context, *DeleteRequest) (*DeleteResponse, error)
func (UnimplementedArticleServer) DeleteArticles ¶
func (UnimplementedArticleServer) DeleteArticles(context.Context, *DeleteArticlesRequest) (*DeleteArticlesResponse, error)
func (UnimplementedArticleServer) Get ¶
func (UnimplementedArticleServer) Get(context.Context, *GetRequest) (*GetResponse, error)
func (UnimplementedArticleServer) GetArticles ¶
func (UnimplementedArticleServer) GetArticles(context.Context, *emptypb.Empty) (*GetArticlesResponse, error)
func (UnimplementedArticleServer) Update ¶
func (UnimplementedArticleServer) Update(context.Context, *UpdateRequest) (*UpdateResponse, error)
type UnsafeArticleServer ¶
type UnsafeArticleServer interface {
// contains filtered or unexported methods
}
UnsafeArticleServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ArticleServer will result in compilation errors.
type UpdateRequest ¶
type UpdateRequest struct { Title string `protobuf:"bytes,1,opt,name=title,proto3" json:"title,omitempty"` Summary string `protobuf:"bytes,2,opt,name=summary,proto3" json:"summary,omitempty"` Article string `protobuf:"bytes,3,opt,name=article,proto3" json:"article,omitempty"` Tags []string `protobuf:"bytes,4,rep,name=tags,proto3" json:"tags,omitempty"` Attachments []string `protobuf:"bytes,5,rep,name=attachments,proto3" json:"attachments,omitempty"` Id int64 `protobuf:"varint,6,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*UpdateRequest) Descriptor
deprecated
func (*UpdateRequest) Descriptor() ([]byte, []int)
Deprecated: Use UpdateRequest.ProtoReflect.Descriptor instead.
func (*UpdateRequest) GetArticle ¶
func (x *UpdateRequest) GetArticle() string
func (*UpdateRequest) GetAttachments ¶
func (x *UpdateRequest) GetAttachments() []string
func (*UpdateRequest) GetId ¶
func (x *UpdateRequest) GetId() int64
func (*UpdateRequest) GetSummary ¶
func (x *UpdateRequest) GetSummary() string
func (*UpdateRequest) GetTags ¶
func (x *UpdateRequest) GetTags() []string
func (*UpdateRequest) GetTitle ¶
func (x *UpdateRequest) GetTitle() string
func (*UpdateRequest) ProtoMessage ¶
func (*UpdateRequest) ProtoMessage()
func (*UpdateRequest) ProtoReflect ¶
func (x *UpdateRequest) ProtoReflect() protoreflect.Message
func (*UpdateRequest) Reset ¶
func (x *UpdateRequest) Reset()
func (*UpdateRequest) String ¶
func (x *UpdateRequest) String() string
type UpdateResponse ¶
type UpdateResponse struct { Code string `protobuf:"bytes,1,opt,name=code,proto3" json:"code,omitempty"` Status string `protobuf:"bytes,2,opt,name=status,proto3" json:"status,omitempty"` // contains filtered or unexported fields }
func (*UpdateResponse) Descriptor
deprecated
func (*UpdateResponse) Descriptor() ([]byte, []int)
Deprecated: Use UpdateResponse.ProtoReflect.Descriptor instead.
func (*UpdateResponse) GetCode ¶
func (x *UpdateResponse) GetCode() string
func (*UpdateResponse) GetStatus ¶
func (x *UpdateResponse) GetStatus() string
func (*UpdateResponse) ProtoMessage ¶
func (*UpdateResponse) ProtoMessage()
func (*UpdateResponse) ProtoReflect ¶
func (x *UpdateResponse) ProtoReflect() protoreflect.Message
func (*UpdateResponse) Reset ¶
func (x *UpdateResponse) Reset()
func (*UpdateResponse) String ¶
func (x *UpdateResponse) String() string