Documentation ¶
Index ¶
- Variables
- func RegisterPolicyPrepareServer(s grpc.ServiceRegistrar, srv PolicyPrepareServer)
- type CreateReq
- type CreateRes
- type DeleteReq
- type DeleteRes
- type GetListReq
- func (*GetListReq) Descriptor() ([]byte, []int)deprecated
- func (x *GetListReq) GetName() string
- func (x *GetListReq) GetPage() int32
- func (x *GetListReq) GetPageSize() int32
- func (*GetListReq) ProtoMessage()
- func (x *GetListReq) ProtoReflect() protoreflect.Message
- func (x *GetListReq) Reset()
- func (x *GetListReq) String() string
- type GetListRes
- func (*GetListRes) Descriptor() ([]byte, []int)deprecated
- func (x *GetListRes) GetPolicyPrepares() []*pbentity.PolicyPrepare
- func (x *GetListRes) GetTotal() int32
- func (*GetListRes) ProtoMessage()
- func (x *GetListRes) ProtoReflect() protoreflect.Message
- func (x *GetListRes) Reset()
- func (x *GetListRes) String() string
- type GetOneReq
- type GetOneRes
- type PolicyPrepareClient
- type PolicyPrepareServer
- type UnimplementedPolicyPrepareServer
- func (UnimplementedPolicyPrepareServer) Create(context.Context, *CreateReq) (*CreateRes, error)
- func (UnimplementedPolicyPrepareServer) Delete(context.Context, *DeleteReq) (*DeleteRes, error)
- func (UnimplementedPolicyPrepareServer) GetList(context.Context, *GetListReq) (*GetListRes, error)
- func (UnimplementedPolicyPrepareServer) GetOne(context.Context, *GetOneReq) (*GetOneRes, error)
- func (UnimplementedPolicyPrepareServer) Update(context.Context, *UpdateReq) (*UpdateRes, error)
- type UnsafePolicyPrepareServer
- type UpdateReq
- func (*UpdateReq) Descriptor() ([]byte, []int)deprecated
- func (x *UpdateReq) GetId() int32
- func (x *UpdateReq) GetName() string
- func (x *UpdateReq) GetPolicy() string
- func (*UpdateReq) ProtoMessage()
- func (x *UpdateReq) ProtoReflect() protoreflect.Message
- func (x *UpdateReq) Reset()
- func (x *UpdateReq) String() string
- type UpdateRes
Constants ¶
This section is empty.
Variables ¶
var File_policy_prepare_v1_policy_prepare_proto protoreflect.FileDescriptor
var PolicyPrepare_ServiceDesc = grpc.ServiceDesc{ ServiceName: "policy_prepare.v1.PolicyPrepare", HandlerType: (*PolicyPrepareServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Create", Handler: _PolicyPrepare_Create_Handler, }, { MethodName: "GetOne", Handler: _PolicyPrepare_GetOne_Handler, }, { MethodName: "GetList", Handler: _PolicyPrepare_GetList_Handler, }, { MethodName: "Update", Handler: _PolicyPrepare_Update_Handler, }, { MethodName: "Delete", Handler: _PolicyPrepare_Delete_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "policy_prepare/v1/policy_prepare.proto", }
PolicyPrepare_ServiceDesc is the grpc.ServiceDesc for PolicyPrepare service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterPolicyPrepareServer ¶
func RegisterPolicyPrepareServer(s grpc.ServiceRegistrar, srv PolicyPrepareServer)
Types ¶
type CreateReq ¶
type CreateReq struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty" v:"required"` // v:required Policy string `protobuf:"bytes,2,opt,name=policy,proto3" json:"policy,omitempty" v:"required|json"` // v:required|json // contains filtered or unexported fields }
func (*CreateReq) Descriptor
deprecated
func (*CreateReq) ProtoMessage ¶
func (*CreateReq) ProtoMessage()
func (*CreateReq) ProtoReflect ¶
func (x *CreateReq) ProtoReflect() protoreflect.Message
type CreateRes ¶
type CreateRes struct { Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*CreateRes) Descriptor
deprecated
func (*CreateRes) ProtoMessage ¶
func (*CreateRes) ProtoMessage()
func (*CreateRes) ProtoReflect ¶
func (x *CreateRes) ProtoReflect() protoreflect.Message
type DeleteReq ¶
type DeleteReq struct { Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty" v:"required"` // v:required // contains filtered or unexported fields }
func (*DeleteReq) Descriptor
deprecated
func (*DeleteReq) ProtoMessage ¶
func (*DeleteReq) ProtoMessage()
func (*DeleteReq) ProtoReflect ¶
func (x *DeleteReq) ProtoReflect() protoreflect.Message
type DeleteRes ¶
type DeleteRes struct { Empty *emptypb.Empty `protobuf:"bytes,1,opt,name=empty,proto3" json:"empty,omitempty"` // contains filtered or unexported fields }
func (*DeleteRes) Descriptor
deprecated
func (*DeleteRes) ProtoMessage ¶
func (*DeleteRes) ProtoMessage()
func (*DeleteRes) ProtoReflect ¶
func (x *DeleteRes) ProtoReflect() protoreflect.Message
type GetListReq ¶
type GetListReq struct { Page int32 `protobuf:"varint,1,opt,name=page,proto3" json:"page,omitempty" v:"required"` // v:required PageSize int32 `protobuf:"varint,2,opt,name=pageSize,proto3" json:"pageSize,omitempty" v:"required|max:100"` // v:required|max:100 Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty" v:"length:1,20"` // v:length:1,20 // contains filtered or unexported fields }
func (*GetListReq) Descriptor
deprecated
func (*GetListReq) Descriptor() ([]byte, []int)
Deprecated: Use GetListReq.ProtoReflect.Descriptor instead.
func (*GetListReq) GetName ¶
func (x *GetListReq) GetName() string
func (*GetListReq) GetPage ¶
func (x *GetListReq) GetPage() int32
func (*GetListReq) GetPageSize ¶
func (x *GetListReq) GetPageSize() int32
func (*GetListReq) ProtoMessage ¶
func (*GetListReq) ProtoMessage()
func (*GetListReq) ProtoReflect ¶
func (x *GetListReq) ProtoReflect() protoreflect.Message
func (*GetListReq) Reset ¶
func (x *GetListReq) Reset()
func (*GetListReq) String ¶
func (x *GetListReq) String() string
type GetListRes ¶
type GetListRes struct { PolicyPrepares []*pbentity.PolicyPrepare `protobuf:"bytes,1,rep,name=policy_prepares,json=policyPrepares,proto3" json:"policy_prepares,omitempty"` Total int32 `protobuf:"varint,2,opt,name=total,proto3" json:"total,omitempty"` // contains filtered or unexported fields }
func (*GetListRes) Descriptor
deprecated
func (*GetListRes) Descriptor() ([]byte, []int)
Deprecated: Use GetListRes.ProtoReflect.Descriptor instead.
func (*GetListRes) GetPolicyPrepares ¶
func (x *GetListRes) GetPolicyPrepares() []*pbentity.PolicyPrepare
func (*GetListRes) GetTotal ¶
func (x *GetListRes) GetTotal() int32
func (*GetListRes) ProtoMessage ¶
func (*GetListRes) ProtoMessage()
func (*GetListRes) ProtoReflect ¶
func (x *GetListRes) ProtoReflect() protoreflect.Message
func (*GetListRes) Reset ¶
func (x *GetListRes) Reset()
func (*GetListRes) String ¶
func (x *GetListRes) String() string
type GetOneReq ¶
type GetOneReq struct { Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty" v:"required"` // v:required // contains filtered or unexported fields }
func (*GetOneReq) Descriptor
deprecated
func (*GetOneReq) ProtoMessage ¶
func (*GetOneReq) ProtoMessage()
func (*GetOneReq) ProtoReflect ¶
func (x *GetOneReq) ProtoReflect() protoreflect.Message
type GetOneRes ¶
type GetOneRes struct { PolicyPrepare *pbentity.PolicyPrepare `protobuf:"bytes,1,opt,name=policy_prepare,json=policyPrepare,proto3" json:"policy_prepare,omitempty"` // contains filtered or unexported fields }
func (*GetOneRes) Descriptor
deprecated
func (*GetOneRes) GetPolicyPrepare ¶
func (x *GetOneRes) GetPolicyPrepare() *pbentity.PolicyPrepare
func (*GetOneRes) ProtoMessage ¶
func (*GetOneRes) ProtoMessage()
func (*GetOneRes) ProtoReflect ¶
func (x *GetOneRes) ProtoReflect() protoreflect.Message
type PolicyPrepareClient ¶
type PolicyPrepareClient interface { Create(ctx context.Context, in *CreateReq, opts ...grpc.CallOption) (*CreateRes, error) GetOne(ctx context.Context, in *GetOneReq, opts ...grpc.CallOption) (*GetOneRes, error) GetList(ctx context.Context, in *GetListReq, opts ...grpc.CallOption) (*GetListRes, error) Update(ctx context.Context, in *UpdateReq, opts ...grpc.CallOption) (*UpdateRes, error) Delete(ctx context.Context, in *DeleteReq, opts ...grpc.CallOption) (*DeleteRes, error) }
PolicyPrepareClient is the client API for PolicyPrepare 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 NewPolicyPrepareClient ¶
func NewPolicyPrepareClient(cc grpc.ClientConnInterface) PolicyPrepareClient
type PolicyPrepareServer ¶
type PolicyPrepareServer interface { Create(context.Context, *CreateReq) (*CreateRes, error) GetOne(context.Context, *GetOneReq) (*GetOneRes, error) GetList(context.Context, *GetListReq) (*GetListRes, error) Update(context.Context, *UpdateReq) (*UpdateRes, error) Delete(context.Context, *DeleteReq) (*DeleteRes, error) // contains filtered or unexported methods }
PolicyPrepareServer is the server API for PolicyPrepare service. All implementations must embed UnimplementedPolicyPrepareServer for forward compatibility
type UnimplementedPolicyPrepareServer ¶
type UnimplementedPolicyPrepareServer struct { }
UnimplementedPolicyPrepareServer must be embedded to have forward compatible implementations.
func (UnimplementedPolicyPrepareServer) GetList ¶
func (UnimplementedPolicyPrepareServer) GetList(context.Context, *GetListReq) (*GetListRes, error)
type UnsafePolicyPrepareServer ¶
type UnsafePolicyPrepareServer interface {
// contains filtered or unexported methods
}
UnsafePolicyPrepareServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to PolicyPrepareServer will result in compilation errors.
type UpdateReq ¶
type UpdateReq struct { Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty" v:"required"` // v:required Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty" v:"required"` // v:required Policy string `protobuf:"bytes,3,opt,name=policy,proto3" json:"policy,omitempty" v:"required|json"` // v:required|json // contains filtered or unexported fields }
func (*UpdateReq) Descriptor
deprecated
func (*UpdateReq) ProtoMessage ¶
func (*UpdateReq) ProtoMessage()
func (*UpdateReq) ProtoReflect ¶
func (x *UpdateReq) ProtoReflect() protoreflect.Message
type UpdateRes ¶
type UpdateRes struct { Empty *emptypb.Empty `protobuf:"bytes,1,opt,name=empty,proto3" json:"empty,omitempty"` // contains filtered or unexported fields }
func (*UpdateRes) Descriptor
deprecated
func (*UpdateRes) ProtoMessage ¶
func (*UpdateRes) ProtoMessage()
func (*UpdateRes) ProtoReflect ¶
func (x *UpdateRes) ProtoReflect() protoreflect.Message