S2I64KV

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Nov 7, 2020 License: Apache-2.0 Imports: 7 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var GoUnusedProtection__ int

Functions

This section is empty.

Types

type TCasResultType

type TCasResultType struct {
	Err      TErrorCode `thrift:"err,1" db:"err" json:"err"`
	OldValue int64      `thrift:"oldValue,2" db:"oldValue" json:"oldValue"`
}

Attributes:

  • Err
  • OldValue
var TDataServiceCasDataResult_Success_DEFAULT *TCasResultType

func NewTCasResultType

func NewTCasResultType() *TCasResultType

func (*TCasResultType) GetErr

func (p *TCasResultType) GetErr() TErrorCode

func (*TCasResultType) GetOldValue

func (p *TCasResultType) GetOldValue() int64

func (*TCasResultType) Read

func (p *TCasResultType) Read(iprot thrift.TProtocol) error

func (*TCasResultType) ReadField1

func (p *TCasResultType) ReadField1(iprot thrift.TProtocol) error

func (*TCasResultType) ReadField2

func (p *TCasResultType) ReadField2(iprot thrift.TProtocol) error

func (*TCasResultType) String

func (p *TCasResultType) String() string

func (*TCasResultType) Write

func (p *TCasResultType) Write(oprot thrift.TProtocol) error

type TCasValue

type TCasValue struct {
	OldValue  int64 `thrift:"oldValue,1" db:"oldValue" json:"oldValue"`
	NewValue_ int64 `thrift:"newValue,2" db:"newValue" json:"newValue"`
}

Attributes:

  • OldValue
  • NewValue_
var TDataServiceCasDataArgs_CasVal_DEFAULT *TCasValue

func NewTCasValue

func NewTCasValue() *TCasValue

func (*TCasValue) GetNewValue_

func (p *TCasValue) GetNewValue_() int64

func (*TCasValue) GetOldValue

func (p *TCasValue) GetOldValue() int64

func (*TCasValue) Read

func (p *TCasValue) Read(iprot thrift.TProtocol) error

func (*TCasValue) ReadField1

func (p *TCasValue) ReadField1(iprot thrift.TProtocol) error

func (*TCasValue) ReadField2

func (p *TCasValue) ReadField2(iprot thrift.TProtocol) error

func (*TCasValue) String

func (p *TCasValue) String() string

func (*TCasValue) Write

func (p *TCasValue) Write(oprot thrift.TProtocol) error

type TData

type TData *TI64Value

func TDataPtr

func TDataPtr(v TData) *TData

type TDataResult_

type TDataResult_ struct {
	ErrorCode TErrorCode `thrift:"errorCode,1" db:"errorCode" json:"errorCode"`
	Data      *TI64Value `thrift:"data,2" db:"data" json:"data,omitempty"`
}

Attributes:

  • ErrorCode
  • Data
var TDataServiceGetDataResult_Success_DEFAULT *TDataResult_
var TDataServiceRGetDataResult_Success_DEFAULT *TDataResult_

func NewTDataResult_

func NewTDataResult_() *TDataResult_

func (*TDataResult_) GetData

func (p *TDataResult_) GetData() *TI64Value

func (*TDataResult_) GetErrorCode

func (p *TDataResult_) GetErrorCode() TErrorCode

func (*TDataResult_) IsSetData

func (p *TDataResult_) IsSetData() bool

func (*TDataResult_) Read

func (p *TDataResult_) Read(iprot thrift.TProtocol) error

func (*TDataResult_) ReadField1

func (p *TDataResult_) ReadField1(iprot thrift.TProtocol) error

func (*TDataResult_) ReadField2

func (p *TDataResult_) ReadField2(iprot thrift.TProtocol) error

func (*TDataResult_) String

func (p *TDataResult_) String() string

func (*TDataResult_) Write

func (p *TDataResult_) Write(oprot thrift.TProtocol) error

type TDataService

type TDataService interface {
	// Parameters:
	//  - Key
	GetData(ctx context.Context, key TKey) (r *TDataResult_, err error)
	// Parameters:
	//  - Key
	//  - Data
	PutData(ctx context.Context, key TKey, data *TI64Value) (r TErrorCode, err error)
	// Parameters:
	//  - Key
	//  - CasVal
	CasData(ctx context.Context, key TKey, casVal *TCasValue) (r *TCasResultType, err error)
}

type TDataServiceCasDataArgs

type TDataServiceCasDataArgs struct {
	Key    TKey       `thrift:"key,1" db:"key" json:"key"`
	CasVal *TCasValue `thrift:"casVal,2" db:"casVal" json:"casVal"`
}

Attributes:

  • Key
  • CasVal

func NewTDataServiceCasDataArgs

func NewTDataServiceCasDataArgs() *TDataServiceCasDataArgs

func (*TDataServiceCasDataArgs) GetCasVal

func (p *TDataServiceCasDataArgs) GetCasVal() *TCasValue

func (*TDataServiceCasDataArgs) GetKey

func (p *TDataServiceCasDataArgs) GetKey() TKey

func (*TDataServiceCasDataArgs) IsSetCasVal

func (p *TDataServiceCasDataArgs) IsSetCasVal() bool

func (*TDataServiceCasDataArgs) Read

func (*TDataServiceCasDataArgs) ReadField1

func (p *TDataServiceCasDataArgs) ReadField1(iprot thrift.TProtocol) error

func (*TDataServiceCasDataArgs) ReadField2

func (p *TDataServiceCasDataArgs) ReadField2(iprot thrift.TProtocol) error

func (*TDataServiceCasDataArgs) String

func (p *TDataServiceCasDataArgs) String() string

func (*TDataServiceCasDataArgs) Write

type TDataServiceCasDataResult

type TDataServiceCasDataResult struct {
	Success *TCasResultType `thrift:"success,0" db:"success" json:"success,omitempty"`
}

Attributes:

  • Success

func NewTDataServiceCasDataResult

func NewTDataServiceCasDataResult() *TDataServiceCasDataResult

func (*TDataServiceCasDataResult) GetSuccess

func (p *TDataServiceCasDataResult) GetSuccess() *TCasResultType

func (*TDataServiceCasDataResult) IsSetSuccess

func (p *TDataServiceCasDataResult) IsSetSuccess() bool

func (*TDataServiceCasDataResult) Read

func (*TDataServiceCasDataResult) ReadField0

func (p *TDataServiceCasDataResult) ReadField0(iprot thrift.TProtocol) error

func (*TDataServiceCasDataResult) String

func (p *TDataServiceCasDataResult) String() string

func (*TDataServiceCasDataResult) Write

type TDataServiceClient

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

func NewTDataServiceClient

func NewTDataServiceClient(c thrift.TClient) *TDataServiceClient

func NewTDataServiceClientProtocol

func NewTDataServiceClientProtocol(t thrift.TTransport, iprot thrift.TProtocol, oprot thrift.TProtocol) *TDataServiceClient

func (*TDataServiceClient) CasData

func (p *TDataServiceClient) CasData(ctx context.Context, key TKey, casVal *TCasValue) (r *TCasResultType, err error)

Parameters:

  • Key
  • CasVal

func (*TDataServiceClient) Client_

func (p *TDataServiceClient) Client_() thrift.TClient

func (*TDataServiceClient) GetData

func (p *TDataServiceClient) GetData(ctx context.Context, key TKey) (r *TDataResult_, err error)

Parameters:

  • Key

func (*TDataServiceClient) PutData

func (p *TDataServiceClient) PutData(ctx context.Context, key TKey, data *TI64Value) (r TErrorCode, err error)

Parameters:

  • Key
  • Data

type TDataServiceGetDataArgs

type TDataServiceGetDataArgs struct {
	Key TKey `thrift:"key,1" db:"key" json:"key"`
}

Attributes:

  • Key

func NewTDataServiceGetDataArgs

func NewTDataServiceGetDataArgs() *TDataServiceGetDataArgs

func (*TDataServiceGetDataArgs) GetKey

func (p *TDataServiceGetDataArgs) GetKey() TKey

func (*TDataServiceGetDataArgs) Read

func (*TDataServiceGetDataArgs) ReadField1

func (p *TDataServiceGetDataArgs) ReadField1(iprot thrift.TProtocol) error

func (*TDataServiceGetDataArgs) String

func (p *TDataServiceGetDataArgs) String() string

func (*TDataServiceGetDataArgs) Write

type TDataServiceGetDataResult

type TDataServiceGetDataResult struct {
	Success *TDataResult_ `thrift:"success,0" db:"success" json:"success,omitempty"`
}

Attributes:

  • Success

func NewTDataServiceGetDataResult

func NewTDataServiceGetDataResult() *TDataServiceGetDataResult

func (*TDataServiceGetDataResult) GetSuccess

func (p *TDataServiceGetDataResult) GetSuccess() *TDataResult_

func (*TDataServiceGetDataResult) IsSetSuccess

func (p *TDataServiceGetDataResult) IsSetSuccess() bool

func (*TDataServiceGetDataResult) Read

func (*TDataServiceGetDataResult) ReadField0

func (p *TDataServiceGetDataResult) ReadField0(iprot thrift.TProtocol) error

func (*TDataServiceGetDataResult) String

func (p *TDataServiceGetDataResult) String() string

func (*TDataServiceGetDataResult) Write

type TDataServiceProcessor

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

func NewTDataServiceProcessor

func NewTDataServiceProcessor(handler TDataService) *TDataServiceProcessor

func (*TDataServiceProcessor) AddToProcessorMap

func (p *TDataServiceProcessor) AddToProcessorMap(key string, processor thrift.TProcessorFunction)

func (*TDataServiceProcessor) GetProcessorFunction

func (p *TDataServiceProcessor) GetProcessorFunction(key string) (processor thrift.TProcessorFunction, ok bool)

func (*TDataServiceProcessor) Process

func (p *TDataServiceProcessor) Process(ctx context.Context, iprot, oprot thrift.TProtocol) (success bool, err thrift.TException)

func (*TDataServiceProcessor) ProcessorMap

func (p *TDataServiceProcessor) ProcessorMap() map[string]thrift.TProcessorFunction

type TDataServicePutDataArgs

type TDataServicePutDataArgs struct {
	Key  TKey       `thrift:"key,1" db:"key" json:"key"`
	Data *TI64Value `thrift:"data,2" db:"data" json:"data"`
}

Attributes:

  • Key
  • Data

func NewTDataServicePutDataArgs

func NewTDataServicePutDataArgs() *TDataServicePutDataArgs

func (*TDataServicePutDataArgs) GetData

func (p *TDataServicePutDataArgs) GetData() *TI64Value

func (*TDataServicePutDataArgs) GetKey

func (p *TDataServicePutDataArgs) GetKey() TKey

func (*TDataServicePutDataArgs) IsSetData

func (p *TDataServicePutDataArgs) IsSetData() bool

func (*TDataServicePutDataArgs) Read

func (*TDataServicePutDataArgs) ReadField1

func (p *TDataServicePutDataArgs) ReadField1(iprot thrift.TProtocol) error

func (*TDataServicePutDataArgs) ReadField2

func (p *TDataServicePutDataArgs) ReadField2(iprot thrift.TProtocol) error

func (*TDataServicePutDataArgs) String

func (p *TDataServicePutDataArgs) String() string

func (*TDataServicePutDataArgs) Write

type TDataServicePutDataResult

type TDataServicePutDataResult struct {
	Success *TErrorCode `thrift:"success,0" db:"success" json:"success,omitempty"`
}

Attributes:

  • Success

func NewTDataServicePutDataResult

func NewTDataServicePutDataResult() *TDataServicePutDataResult

func (*TDataServicePutDataResult) GetSuccess

func (p *TDataServicePutDataResult) GetSuccess() TErrorCode

func (*TDataServicePutDataResult) IsSetSuccess

func (p *TDataServicePutDataResult) IsSetSuccess() bool

func (*TDataServicePutDataResult) Read

func (*TDataServicePutDataResult) ReadField0

func (p *TDataServicePutDataResult) ReadField0(iprot thrift.TProtocol) error

func (*TDataServicePutDataResult) String

func (p *TDataServicePutDataResult) String() string

func (*TDataServicePutDataResult) Write

type TDataServiceR

type TDataServiceR interface {
	// Parameters:
	//  - Key
	GetData(ctx context.Context, key TKey) (r *TDataResult_, err error)
}

type TDataServiceRClient

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

func NewTDataServiceRClient

func NewTDataServiceRClient(c thrift.TClient) *TDataServiceRClient

func NewTDataServiceRClientProtocol

func NewTDataServiceRClientProtocol(t thrift.TTransport, iprot thrift.TProtocol, oprot thrift.TProtocol) *TDataServiceRClient

func (*TDataServiceRClient) Client_

func (p *TDataServiceRClient) Client_() thrift.TClient

func (*TDataServiceRClient) GetData

func (p *TDataServiceRClient) GetData(ctx context.Context, key TKey) (r *TDataResult_, err error)

Parameters:

  • Key

type TDataServiceRGetDataArgs

type TDataServiceRGetDataArgs struct {
	Key TKey `thrift:"key,1" db:"key" json:"key"`
}

Attributes:

  • Key

func NewTDataServiceRGetDataArgs

func NewTDataServiceRGetDataArgs() *TDataServiceRGetDataArgs

func (*TDataServiceRGetDataArgs) GetKey

func (p *TDataServiceRGetDataArgs) GetKey() TKey

func (*TDataServiceRGetDataArgs) Read

func (*TDataServiceRGetDataArgs) ReadField1

func (p *TDataServiceRGetDataArgs) ReadField1(iprot thrift.TProtocol) error

func (*TDataServiceRGetDataArgs) String

func (p *TDataServiceRGetDataArgs) String() string

func (*TDataServiceRGetDataArgs) Write

type TDataServiceRGetDataResult

type TDataServiceRGetDataResult struct {
	Success *TDataResult_ `thrift:"success,0" db:"success" json:"success,omitempty"`
}

Attributes:

  • Success

func NewTDataServiceRGetDataResult

func NewTDataServiceRGetDataResult() *TDataServiceRGetDataResult

func (*TDataServiceRGetDataResult) GetSuccess

func (p *TDataServiceRGetDataResult) GetSuccess() *TDataResult_

func (*TDataServiceRGetDataResult) IsSetSuccess

func (p *TDataServiceRGetDataResult) IsSetSuccess() bool

func (*TDataServiceRGetDataResult) Read

func (*TDataServiceRGetDataResult) ReadField0

func (p *TDataServiceRGetDataResult) ReadField0(iprot thrift.TProtocol) error

func (*TDataServiceRGetDataResult) String

func (p *TDataServiceRGetDataResult) String() string

func (*TDataServiceRGetDataResult) Write

type TDataServiceRProcessor

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

func NewTDataServiceRProcessor

func NewTDataServiceRProcessor(handler TDataServiceR) *TDataServiceRProcessor

func (*TDataServiceRProcessor) AddToProcessorMap

func (p *TDataServiceRProcessor) AddToProcessorMap(key string, processor thrift.TProcessorFunction)

func (*TDataServiceRProcessor) GetProcessorFunction

func (p *TDataServiceRProcessor) GetProcessorFunction(key string) (processor thrift.TProcessorFunction, ok bool)

func (*TDataServiceRProcessor) Process

func (p *TDataServiceRProcessor) Process(ctx context.Context, iprot, oprot thrift.TProtocol) (success bool, err thrift.TException)

func (*TDataServiceRProcessor) ProcessorMap

type TErrorCode

type TErrorCode int64
const (
	TErrorCode_EGood        TErrorCode = 0
	TErrorCode_ENotFound    TErrorCode = -1
	TErrorCode_EUnknown     TErrorCode = -2
	TErrorCode_EDataExisted TErrorCode = -3
	TErrorCode_ECasFailed   TErrorCode = -4
)
var TDataServicePutDataResult_Success_DEFAULT TErrorCode

func TErrorCodeFromString

func TErrorCodeFromString(s string) (TErrorCode, error)

func TErrorCodePtr

func TErrorCodePtr(v TErrorCode) *TErrorCode

func (TErrorCode) MarshalText

func (p TErrorCode) MarshalText() ([]byte, error)

func (*TErrorCode) Scan

func (p *TErrorCode) Scan(value interface{}) error

func (TErrorCode) String

func (p TErrorCode) String() string

func (*TErrorCode) UnmarshalText

func (p *TErrorCode) UnmarshalText(text []byte) error

func (*TErrorCode) Value

func (p *TErrorCode) Value() (driver.Value, error)

type TI64Value

type TI64Value struct {
	Value int64 `thrift:"value,1" db:"value" json:"value"`
}

Attributes:

  • Value
var TDataResult__Data_DEFAULT *TI64Value
var TDataServicePutDataArgs_Data_DEFAULT *TI64Value

func NewTI64Value

func NewTI64Value() *TI64Value

func (*TI64Value) GetValue

func (p *TI64Value) GetValue() int64

func (*TI64Value) Read

func (p *TI64Value) Read(iprot thrift.TProtocol) error

func (*TI64Value) ReadField1

func (p *TI64Value) ReadField1(iprot thrift.TProtocol) error

func (*TI64Value) String

func (p *TI64Value) String() string

func (*TI64Value) Write

func (p *TI64Value) Write(oprot thrift.TProtocol) error

type TKey

type TKey string

func TKeyPtr

func TKeyPtr(v TKey) *TKey

type TString2I64KVService

type TString2I64KVService interface {
	TDataService
}

type TString2I64KVServiceClient

type TString2I64KVServiceClient struct {
	*TDataServiceClient
}

func NewTString2I64KVServiceClient

func NewTString2I64KVServiceClient(c thrift.TClient) *TString2I64KVServiceClient

func NewTString2I64KVServiceClientProtocol

func NewTString2I64KVServiceClientProtocol(t thrift.TTransport, iprot thrift.TProtocol, oprot thrift.TProtocol) *TString2I64KVServiceClient

type TString2I64KVServiceProcessor

type TString2I64KVServiceProcessor struct {
	*TDataServiceProcessor
}

func NewTString2I64KVServiceProcessor

func NewTString2I64KVServiceProcessor(handler TString2I64KVService) *TString2I64KVServiceProcessor

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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