device

package
v0.0.0-...-b08fcc5 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2023 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_proto_device_device_proto protoreflect.FileDescriptor

Functions

func NewUserDeviceEndpoints

func NewUserDeviceEndpoints() []*api.Endpoint

func RegisterUserDeviceHandler

func RegisterUserDeviceHandler(s server.Server, hdlr UserDeviceHandler, opts ...server.HandlerOption) error

Types

type Device

type Device struct {
	Platform          string `protobuf:"bytes,1,opt,name=Platform,proto3" json:"Platform"`                   // 平台
	Language          string `protobuf:"bytes,2,opt,name=Language,proto3" json:"Language"`                   //  语言
	Version           string `protobuf:"bytes,3,opt,name=Version,proto3" json:"Version"`                     //  版本
	DeviceFingerprint string `protobuf:"bytes,4,opt,name=DeviceFingerprint,proto3" json:"DeviceFingerprint"` // 设备指纹
	DeviceName        string `protobuf:"bytes,5,opt,name=DeviceName,proto3" json:"DeviceName"`               // 设备名称
	Token             string `protobuf:"bytes,6,opt,name=Token,proto3" json:"Token"`                         // 当前token
	PlatformApp       string `protobuf:"bytes,7,opt,name=PlatformApp,proto3" json:"PlatformApp"`             // ShowId内部平台
	// contains filtered or unexported fields
}

func (*Device) Descriptor deprecated

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

Deprecated: Use Device.ProtoReflect.Descriptor instead.

func (*Device) GetDeviceFingerprint

func (x *Device) GetDeviceFingerprint() string

func (*Device) GetDeviceName

func (x *Device) GetDeviceName() string

func (*Device) GetLanguage

func (x *Device) GetLanguage() string

func (*Device) GetPlatform

func (x *Device) GetPlatform() string

func (*Device) GetPlatformApp

func (x *Device) GetPlatformApp() string

func (*Device) GetToken

func (x *Device) GetToken() string

func (*Device) GetVersion

func (x *Device) GetVersion() string

func (*Device) ProtoMessage

func (*Device) ProtoMessage()

func (*Device) ProtoReflect

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

func (*Device) Reset

func (x *Device) Reset()

func (*Device) String

func (x *Device) String() string

func (*Device) Validate

func (m *Device) Validate() error

Validate checks the field values on Device with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Device) ValidateAll

func (m *Device) ValidateAll() error

ValidateAll checks the field values on Device with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in DeviceMultiError, or nil if none found.

type DeviceListRequest

type DeviceListRequest struct {
	UserId int64 `protobuf:"varint,1,opt,name=UserId,proto3" json:"UserId"` // 用户ID
	// contains filtered or unexported fields
}

[请求] 获取

func (*DeviceListRequest) Descriptor deprecated

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

Deprecated: Use DeviceListRequest.ProtoReflect.Descriptor instead.

func (*DeviceListRequest) GetUserId

func (x *DeviceListRequest) GetUserId() int64

func (*DeviceListRequest) ProtoMessage

func (*DeviceListRequest) ProtoMessage()

func (*DeviceListRequest) ProtoReflect

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

func (*DeviceListRequest) Reset

func (x *DeviceListRequest) Reset()

func (*DeviceListRequest) String

func (x *DeviceListRequest) String() string

func (*DeviceListRequest) Validate

func (m *DeviceListRequest) Validate() error

Validate checks the field values on DeviceListRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*DeviceListRequest) ValidateAll

func (m *DeviceListRequest) ValidateAll() error

ValidateAll checks the field values on DeviceListRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in DeviceListRequestMultiError, or nil if none found.

type DeviceListRequestMultiError

type DeviceListRequestMultiError []error

DeviceListRequestMultiError is an error wrapping multiple validation errors returned by DeviceListRequest.ValidateAll() if the designated constraints aren't met.

func (DeviceListRequestMultiError) AllErrors

func (m DeviceListRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (DeviceListRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type DeviceListRequestValidationError

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

DeviceListRequestValidationError is the validation error returned by DeviceListRequest.Validate if the designated constraints aren't met.

func (DeviceListRequestValidationError) Cause

Cause function returns cause value.

func (DeviceListRequestValidationError) Error

Error satisfies the builtin error interface

func (DeviceListRequestValidationError) ErrorName

ErrorName returns error name.

func (DeviceListRequestValidationError) Field

Field function returns field value.

func (DeviceListRequestValidationError) Key

Key function returns key value.

func (DeviceListRequestValidationError) Reason

Reason function returns reason value.

type DeviceListResponse

type DeviceListResponse struct {
	Devices []*Device `protobuf:"bytes,1,rep,name=Devices,proto3" json:"Devices"` // 设备列表
	// contains filtered or unexported fields
}

[响应] 获取token

func (*DeviceListResponse) Descriptor deprecated

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

Deprecated: Use DeviceListResponse.ProtoReflect.Descriptor instead.

func (*DeviceListResponse) GetDevices

func (x *DeviceListResponse) GetDevices() []*Device

func (*DeviceListResponse) ProtoMessage

func (*DeviceListResponse) ProtoMessage()

func (*DeviceListResponse) ProtoReflect

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

func (*DeviceListResponse) Reset

func (x *DeviceListResponse) Reset()

func (*DeviceListResponse) String

func (x *DeviceListResponse) String() string

func (*DeviceListResponse) Validate

func (m *DeviceListResponse) Validate() error

Validate checks the field values on DeviceListResponse with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*DeviceListResponse) ValidateAll

func (m *DeviceListResponse) ValidateAll() error

ValidateAll checks the field values on DeviceListResponse with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in DeviceListResponseMultiError, or nil if none found.

type DeviceListResponseMultiError

type DeviceListResponseMultiError []error

DeviceListResponseMultiError is an error wrapping multiple validation errors returned by DeviceListResponse.ValidateAll() if the designated constraints aren't met.

func (DeviceListResponseMultiError) AllErrors

func (m DeviceListResponseMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (DeviceListResponseMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type DeviceListResponseValidationError

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

DeviceListResponseValidationError is the validation error returned by DeviceListResponse.Validate if the designated constraints aren't met.

func (DeviceListResponseValidationError) Cause

Cause function returns cause value.

func (DeviceListResponseValidationError) Error

Error satisfies the builtin error interface

func (DeviceListResponseValidationError) ErrorName

ErrorName returns error name.

func (DeviceListResponseValidationError) Field

Field function returns field value.

func (DeviceListResponseValidationError) Key

Key function returns key value.

func (DeviceListResponseValidationError) Reason

Reason function returns reason value.

type DeviceMultiError

type DeviceMultiError []error

DeviceMultiError is an error wrapping multiple validation errors returned by Device.ValidateAll() if the designated constraints aren't met.

func (DeviceMultiError) AllErrors

func (m DeviceMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (DeviceMultiError) Error

func (m DeviceMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type DeviceValidationError

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

DeviceValidationError is the validation error returned by Device.Validate if the designated constraints aren't met.

func (DeviceValidationError) Cause

func (e DeviceValidationError) Cause() error

Cause function returns cause value.

func (DeviceValidationError) Error

func (e DeviceValidationError) Error() string

Error satisfies the builtin error interface

func (DeviceValidationError) ErrorName

func (e DeviceValidationError) ErrorName() string

ErrorName returns error name.

func (DeviceValidationError) Field

func (e DeviceValidationError) Field() string

Field function returns field value.

func (DeviceValidationError) Key

func (e DeviceValidationError) Key() bool

Key function returns key value.

func (DeviceValidationError) Reason

func (e DeviceValidationError) Reason() string

Reason function returns reason value.

type UserDeviceHandler

type UserDeviceHandler interface {
	List(context.Context, *DeviceListRequest, *DeviceListResponse) error
}

type UserDeviceService

type UserDeviceService interface {
	List(ctx context.Context, in *DeviceListRequest, opts ...client.CallOption) (*DeviceListResponse, error)
}

func NewUserDeviceService

func NewUserDeviceService(name string, c client.Client) UserDeviceService

Jump to

Keyboard shortcuts

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