Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Accessor ¶
type Accessor struct {
// contains filtered or unexported fields
}
Accessor is an accessor to in-memory contracts.
func NewContractAccessor ¶
func NewContractAccessor() *Accessor
NewContractAccessor returns new contract accessor's ptr.
type Contract ¶
type Contract struct { ContractorName string `json:"contractorName"` ID ID `json:"contractID"` AvailableServices []string `json:"availableServices,omitempty"` McOpsID McOpsID `json:"mcOpsId,omitempty"` LastUpdatedTs *LastUpdatedTime `json:"lastUpdatedTs"` Quota *pb.ContractQuota `json:"quota"` }
Contract represents a contract data
type ID ¶
type ID string
ID is a global unique ID for the contracts. ID is generated by CBP or external site.
type LastUpdatedTime ¶
LastUpdatedTime renamed time.Time type.
func (LastUpdatedTime) Timestamppb ¶
func (ts LastUpdatedTime) Timestamppb() *timestamppb.Timestamp
Timestamppb converts time.Time type to timestamppb.Timestamp.
func (*LastUpdatedTime) UnmarshalJSON ¶
func (ts *LastUpdatedTime) UnmarshalJSON(data []byte) error
UnmarshalJSON parses the Unix time and stores the result in ts
Click to show internal directories.
Click to hide internal directories.