Documentation
¶
Index ¶
- Variables
- func RegisterHostsServer(s *grpc.Server, srv HostsServer)
- func RegisterSettingsServer(s *grpc.Server, srv SettingsServer)
- type BandwidthInfo
- func (*BandwidthInfo) Descriptor() ([]byte, []int)
- func (m *BandwidthInfo) GetBandwidthAskPrice() float32
- func (m *BandwidthInfo) GetBandwidthLimit() float32
- func (m *BandwidthInfo) GetBandwidthPriceEst() float32
- func (m *BandwidthInfo) Marshal() (dAtA []byte, err error)
- func (m *BandwidthInfo) MarshalTo(dAtA []byte) (int, error)
- func (m *BandwidthInfo) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*BandwidthInfo) ProtoMessage()
- func (m *BandwidthInfo) Reset()
- func (m *BandwidthInfo) Size() (n int)
- func (m *BandwidthInfo) String() string
- func (m *BandwidthInfo) Unmarshal(dAtA []byte) error
- func (m *BandwidthInfo) XXX_DiscardUnknown()
- func (m *BandwidthInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *BandwidthInfo) XXX_Merge(src proto.Message)
- func (*BandwidthInfo) XXX_MessageName() string
- func (m *BandwidthInfo) XXX_Size() int
- func (m *BandwidthInfo) XXX_Unmarshal(b []byte) error
- type CollateralInfo
- func (*CollateralInfo) Descriptor() ([]byte, []int)
- func (m *CollateralInfo) GetCollateralBurn() float32
- func (m *CollateralInfo) GetCollateralLost() float32
- func (m *CollateralInfo) GetCollateralStake() float32
- func (m *CollateralInfo) Marshal() (dAtA []byte, err error)
- func (m *CollateralInfo) MarshalTo(dAtA []byte) (int, error)
- func (m *CollateralInfo) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*CollateralInfo) ProtoMessage()
- func (m *CollateralInfo) Reset()
- func (m *CollateralInfo) Size() (n int)
- func (m *CollateralInfo) String() string
- func (m *CollateralInfo) Unmarshal(dAtA []byte) error
- func (m *CollateralInfo) XXX_DiscardUnknown()
- func (m *CollateralInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *CollateralInfo) XXX_Merge(src proto.Message)
- func (*CollateralInfo) XXX_MessageName() string
- func (m *CollateralInfo) XXX_Size() int
- func (m *CollateralInfo) XXX_Unmarshal(b []byte) error
- type Host
- func (*Host) Descriptor() ([]byte, []int)
- func (m *Host) GetAge() int64
- func (m *Host) GetBandwidthInfo() *BandwidthInfo
- func (m *Host) GetBtfsVersion() string
- func (m *Host) GetCollateralInfo() *CollateralInfo
- func (m *Host) GetDownloadAvg() float32
- func (m *Host) GetDownloadVar() float32
- func (m *Host) GetHeartBeats() int64
- func (m *Host) GetLocation() *Location
- func (m *Host) GetNodeId() string
- func (m *Host) GetNodeIp() string
- func (m *Host) GetRegion() string
- func (m *Host) GetReputation() float32
- func (m *Host) GetScore() float32
- func (m *Host) GetStorageInfo() *StorageInfo
- func (m *Host) GetTimeCreate() time.Time
- func (m *Host) GetTimeUpdate() time.Time
- func (m *Host) GetUploadAvg() float32
- func (m *Host) GetUploadVar() float32
- func (m *Host) GetUptime() float32
- func (m *Host) Marshal() (dAtA []byte, err error)
- func (m *Host) MarshalTo(dAtA []byte) (int, error)
- func (m *Host) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Host) ProtoMessage()
- func (m *Host) Reset()
- func (m *Host) Size() (n int)
- func (m *Host) String() string
- func (m *Host) Unmarshal(dAtA []byte) error
- func (m *Host) XXX_DiscardUnknown()
- func (m *Host) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Host) XXX_Merge(src proto.Message)
- func (*Host) XXX_MessageName() string
- func (m *Host) XXX_Size() int
- func (m *Host) XXX_Unmarshal(b []byte) error
- type HostsClient
- type HostsData
- func (*HostsData) Descriptor() ([]byte, []int)
- func (m *HostsData) GetHosts() []*Host
- func (m *HostsData) Marshal() (dAtA []byte, err error)
- func (m *HostsData) MarshalTo(dAtA []byte) (int, error)
- func (m *HostsData) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*HostsData) ProtoMessage()
- func (m *HostsData) Reset()
- func (m *HostsData) Size() (n int)
- func (m *HostsData) String() string
- func (m *HostsData) Unmarshal(dAtA []byte) error
- func (m *HostsData) XXX_DiscardUnknown()
- func (m *HostsData) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *HostsData) XXX_Merge(src proto.Message)
- func (*HostsData) XXX_MessageName() string
- func (m *HostsData) XXX_Size() int
- func (m *HostsData) XXX_Unmarshal(b []byte) error
- type HostsReq
- func (*HostsReq) Descriptor() ([]byte, []int)
- func (m *HostsReq) GetId() string
- func (m *HostsReq) GetRespSize() int32
- func (m *HostsReq) Marshal() (dAtA []byte, err error)
- func (m *HostsReq) MarshalTo(dAtA []byte) (int, error)
- func (m *HostsReq) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*HostsReq) ProtoMessage()
- func (m *HostsReq) Reset()
- func (m *HostsReq) Size() (n int)
- func (m *HostsReq) String() string
- func (m *HostsReq) Unmarshal(dAtA []byte) error
- func (m *HostsReq) XXX_DiscardUnknown()
- func (m *HostsReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *HostsReq) XXX_Merge(src proto.Message)
- func (*HostsReq) XXX_MessageName() string
- func (m *HostsReq) XXX_Size() int
- func (m *HostsReq) XXX_Unmarshal(b []byte) error
- type HostsResp
- func (*HostsResp) Descriptor() ([]byte, []int)
- func (m *HostsResp) GetCode() ResponseCode
- func (m *HostsResp) GetHosts() *HostsData
- func (m *HostsResp) GetMessage() string
- func (m *HostsResp) GetMode() string
- func (m *HostsResp) GetRespSize() int32
- func (m *HostsResp) GetResponseTime() time.Time
- func (m *HostsResp) Marshal() (dAtA []byte, err error)
- func (m *HostsResp) MarshalTo(dAtA []byte) (int, error)
- func (m *HostsResp) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*HostsResp) ProtoMessage()
- func (m *HostsResp) Reset()
- func (m *HostsResp) Size() (n int)
- func (m *HostsResp) String() string
- func (m *HostsResp) Unmarshal(dAtA []byte) error
- func (m *HostsResp) XXX_DiscardUnknown()
- func (m *HostsResp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *HostsResp) XXX_Merge(src proto.Message)
- func (*HostsResp) XXX_MessageName() string
- func (m *HostsResp) XXX_Size() int
- func (m *HostsResp) XXX_Unmarshal(b []byte) error
- type HostsServer
- type Location
- func (*Location) Descriptor() ([]byte, []int)
- func (m *Location) GetLat() float64
- func (m *Location) GetLon() float64
- func (m *Location) Marshal() (dAtA []byte, err error)
- func (m *Location) MarshalTo(dAtA []byte) (int, error)
- func (m *Location) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Location) ProtoMessage()
- func (m *Location) Reset()
- func (m *Location) Size() (n int)
- func (m *Location) String() string
- func (m *Location) Unmarshal(dAtA []byte) error
- func (m *Location) XXX_DiscardUnknown()
- func (m *Location) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Location) XXX_Merge(src proto.Message)
- func (*Location) XXX_MessageName() string
- func (m *Location) XXX_Size() int
- func (m *Location) XXX_Unmarshal(b []byte) error
- type ResponseCode
- type SettingsClient
- type SettingsData
- func (*SettingsData) Descriptor() ([]byte, []int)
- func (m *SettingsData) GetBandwidthLimit() float64
- func (m *SettingsData) GetBandwidthPriceAsk() float64
- func (m *SettingsData) GetCollateralStake() float64
- func (m *SettingsData) GetStoragePriceAsk() float64
- func (m *SettingsData) GetStorageTimeMin() float64
- func (m *SettingsData) Marshal() (dAtA []byte, err error)
- func (m *SettingsData) MarshalTo(dAtA []byte) (int, error)
- func (m *SettingsData) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*SettingsData) ProtoMessage()
- func (m *SettingsData) Reset()
- func (m *SettingsData) Size() (n int)
- func (m *SettingsData) String() string
- func (m *SettingsData) Unmarshal(dAtA []byte) error
- func (m *SettingsData) XXX_DiscardUnknown()
- func (m *SettingsData) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SettingsData) XXX_Merge(src proto.Message)
- func (*SettingsData) XXX_MessageName() string
- func (m *SettingsData) XXX_Size() int
- func (m *SettingsData) XXX_Unmarshal(b []byte) error
- type SettingsReq
- func (*SettingsReq) Descriptor() ([]byte, []int)
- func (m *SettingsReq) GetId() string
- func (m *SettingsReq) GetRespSize() int32
- func (m *SettingsReq) Marshal() (dAtA []byte, err error)
- func (m *SettingsReq) MarshalTo(dAtA []byte) (int, error)
- func (m *SettingsReq) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*SettingsReq) ProtoMessage()
- func (m *SettingsReq) Reset()
- func (m *SettingsReq) Size() (n int)
- func (m *SettingsReq) String() string
- func (m *SettingsReq) Unmarshal(dAtA []byte) error
- func (m *SettingsReq) XXX_DiscardUnknown()
- func (m *SettingsReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SettingsReq) XXX_Merge(src proto.Message)
- func (*SettingsReq) XXX_MessageName() string
- func (m *SettingsReq) XXX_Size() int
- func (m *SettingsReq) XXX_Unmarshal(b []byte) error
- type SettingsResp
- func (*SettingsResp) Descriptor() ([]byte, []int)
- func (m *SettingsResp) GetCode() ResponseCode
- func (m *SettingsResp) GetMessage() string
- func (m *SettingsResp) GetResponseTime() time.Time
- func (m *SettingsResp) GetSettingsData() *SettingsData
- func (m *SettingsResp) Marshal() (dAtA []byte, err error)
- func (m *SettingsResp) MarshalTo(dAtA []byte) (int, error)
- func (m *SettingsResp) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*SettingsResp) ProtoMessage()
- func (m *SettingsResp) Reset()
- func (m *SettingsResp) Size() (n int)
- func (m *SettingsResp) String() string
- func (m *SettingsResp) Unmarshal(dAtA []byte) error
- func (m *SettingsResp) XXX_DiscardUnknown()
- func (m *SettingsResp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SettingsResp) XXX_Merge(src proto.Message)
- func (*SettingsResp) XXX_MessageName() string
- func (m *SettingsResp) XXX_Size() int
- func (m *SettingsResp) XXX_Unmarshal(b []byte) error
- type SettingsServer
- type StorageInfo
- func (*StorageInfo) Descriptor() ([]byte, []int)
- func (m *StorageInfo) GetStorageAskPrice() float32
- func (m *StorageInfo) GetStorageCap() float32
- func (m *StorageInfo) GetStorageLeft() float32
- func (m *StorageInfo) GetStorageMinTime() int64
- func (m *StorageInfo) GetStoragePriceEst() float32
- func (m *StorageInfo) Marshal() (dAtA []byte, err error)
- func (m *StorageInfo) MarshalTo(dAtA []byte) (int, error)
- func (m *StorageInfo) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*StorageInfo) ProtoMessage()
- func (m *StorageInfo) Reset()
- func (m *StorageInfo) Size() (n int)
- func (m *StorageInfo) String() string
- func (m *StorageInfo) Unmarshal(dAtA []byte) error
- func (m *StorageInfo) XXX_DiscardUnknown()
- func (m *StorageInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *StorageInfo) XXX_Merge(src proto.Message)
- func (*StorageInfo) XXX_MessageName() string
- func (m *StorageInfo) XXX_Size() int
- func (m *StorageInfo) XXX_Unmarshal(b []byte) error
- type UnimplementedHostsServer
- type UnimplementedSettingsServer
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrInvalidLengthHub = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowHub = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupHub = fmt.Errorf("proto: unexpected end of group") )
View Source
var ResponseCode_name = map[int32]string{
0: "SUCCESS",
1: "SIGNATURE_FORMAT_ERROR",
2: "COMPUTE_ADDRESS_ERROR",
20: "OTHER_ERROR",
}
View Source
var ResponseCode_value = map[string]int32{
"SUCCESS": 0,
"SIGNATURE_FORMAT_ERROR": 1,
"COMPUTE_ADDRESS_ERROR": 2,
"OTHER_ERROR": 20,
}
Functions ¶
func RegisterHostsServer ¶
func RegisterHostsServer(s *grpc.Server, srv HostsServer)
func RegisterSettingsServer ¶
func RegisterSettingsServer(s *grpc.Server, srv SettingsServer)
Types ¶
type BandwidthInfo ¶
type BandwidthInfo struct { BandwidthLimit float32 `` /* 126-byte string literal not displayed */ BandwidthAskPrice float32 `` /* 141-byte string literal not displayed */ BandwidthPriceEst float32 `` /* 141-byte string literal not displayed */ XXX_NoUnkeyedLiteral struct{} `json:"-" pg:"-"` XXX_unrecognized []byte `json:"-" pg:"-"` XXX_sizecache int32 `json:"-" pg:"-"` }
func (*BandwidthInfo) Descriptor ¶
func (*BandwidthInfo) Descriptor() ([]byte, []int)
func (*BandwidthInfo) GetBandwidthAskPrice ¶
func (m *BandwidthInfo) GetBandwidthAskPrice() float32
func (*BandwidthInfo) GetBandwidthLimit ¶
func (m *BandwidthInfo) GetBandwidthLimit() float32
func (*BandwidthInfo) GetBandwidthPriceEst ¶
func (m *BandwidthInfo) GetBandwidthPriceEst() float32
func (*BandwidthInfo) Marshal ¶
func (m *BandwidthInfo) Marshal() (dAtA []byte, err error)
func (*BandwidthInfo) MarshalToSizedBuffer ¶
func (m *BandwidthInfo) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*BandwidthInfo) ProtoMessage ¶
func (*BandwidthInfo) ProtoMessage()
func (*BandwidthInfo) Reset ¶
func (m *BandwidthInfo) Reset()
func (*BandwidthInfo) Size ¶
func (m *BandwidthInfo) Size() (n int)
func (*BandwidthInfo) String ¶
func (m *BandwidthInfo) String() string
func (*BandwidthInfo) Unmarshal ¶
func (m *BandwidthInfo) Unmarshal(dAtA []byte) error
func (*BandwidthInfo) XXX_DiscardUnknown ¶
func (m *BandwidthInfo) XXX_DiscardUnknown()
func (*BandwidthInfo) XXX_Marshal ¶
func (m *BandwidthInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*BandwidthInfo) XXX_Merge ¶
func (m *BandwidthInfo) XXX_Merge(src proto.Message)
func (*BandwidthInfo) XXX_MessageName ¶
func (*BandwidthInfo) XXX_MessageName() string
func (*BandwidthInfo) XXX_Size ¶
func (m *BandwidthInfo) XXX_Size() int
func (*BandwidthInfo) XXX_Unmarshal ¶
func (m *BandwidthInfo) XXX_Unmarshal(b []byte) error
type CollateralInfo ¶
type CollateralInfo struct { CollateralStake float32 `` /* 130-byte string literal not displayed */ CollateralLost float32 `` /* 126-byte string literal not displayed */ CollateralBurn float32 `` /* 126-byte string literal not displayed */ XXX_NoUnkeyedLiteral struct{} `json:"-" pg:"-"` XXX_unrecognized []byte `json:"-" pg:"-"` XXX_sizecache int32 `json:"-" pg:"-"` }
func (*CollateralInfo) Descriptor ¶
func (*CollateralInfo) Descriptor() ([]byte, []int)
func (*CollateralInfo) GetCollateralBurn ¶
func (m *CollateralInfo) GetCollateralBurn() float32
func (*CollateralInfo) GetCollateralLost ¶
func (m *CollateralInfo) GetCollateralLost() float32
func (*CollateralInfo) GetCollateralStake ¶
func (m *CollateralInfo) GetCollateralStake() float32
func (*CollateralInfo) Marshal ¶
func (m *CollateralInfo) Marshal() (dAtA []byte, err error)
func (*CollateralInfo) MarshalToSizedBuffer ¶
func (m *CollateralInfo) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*CollateralInfo) ProtoMessage ¶
func (*CollateralInfo) ProtoMessage()
func (*CollateralInfo) Reset ¶
func (m *CollateralInfo) Reset()
func (*CollateralInfo) Size ¶
func (m *CollateralInfo) Size() (n int)
func (*CollateralInfo) String ¶
func (m *CollateralInfo) String() string
func (*CollateralInfo) Unmarshal ¶
func (m *CollateralInfo) Unmarshal(dAtA []byte) error
func (*CollateralInfo) XXX_DiscardUnknown ¶
func (m *CollateralInfo) XXX_DiscardUnknown()
func (*CollateralInfo) XXX_Marshal ¶
func (m *CollateralInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*CollateralInfo) XXX_Merge ¶
func (m *CollateralInfo) XXX_Merge(src proto.Message)
func (*CollateralInfo) XXX_MessageName ¶
func (*CollateralInfo) XXX_MessageName() string
func (*CollateralInfo) XXX_Size ¶
func (m *CollateralInfo) XXX_Size() int
func (*CollateralInfo) XXX_Unmarshal ¶
func (m *CollateralInfo) XXX_Unmarshal(b []byte) error
type Host ¶
type Host struct { NodeId string `protobuf:"bytes,1,opt,name=node_id,json=nodeId,proto3" json:"node_id,omitempty" pg:"node_id"` TimeCreate time.Time `protobuf:"bytes,2,opt,name=time_create,json=timeCreate,proto3,stdtime" json:"time_create" pg:"time_create"` TimeUpdate time.Time `protobuf:"bytes,3,opt,name=time_update,json=timeUpdate,proto3,stdtime" json:"time_update" pg:"time_update"` NodeIp string `protobuf:"bytes,4,opt,name=node_ip,json=nodeIp,proto3" json:"node_ip,omitempty" pg:"node_ip"` Region string `protobuf:"bytes,5,opt,name=region,proto3" json:"region,omitempty" pg:"region"` BtfsVersion string `protobuf:"bytes,6,opt,name=btfs_version,json=btfsVersion,proto3" json:"btfs_version,omitempty" pg:"btfs_version"` Score float32 `protobuf:"fixed32,7,opt,name=score,proto3" json:"score,omitempty" pg:"score"` HeartBeats int64 `protobuf:"varint,8,opt,name=heart_beats,json=heartBeats,proto3" json:"heart_beats,omitempty" pg:"heart_beats"` Uptime float32 `protobuf:"fixed32,9,opt,name=uptime,proto3" json:"uptime,omitempty" pg:"uptime"` Age int64 `protobuf:"varint,10,opt,name=age,proto3" json:"age,omitempty" pg:"age"` Reputation float32 `protobuf:"fixed32,11,opt,name=reputation,proto3" json:"reputation,omitempty" pg:"reputation"` UploadAvg float32 `protobuf:"fixed32,12,opt,name=upload_avg,json=uploadAvg,proto3" json:"upload_avg,omitempty" pg:"upload_avg"` UploadVar float32 `protobuf:"fixed32,13,opt,name=upload_var,json=uploadVar,proto3" json:"upload_var,omitempty" pg:"upload_var"` DownloadAvg float32 `protobuf:"fixed32,14,opt,name=download_avg,json=downloadAvg,proto3" json:"download_avg,omitempty" pg:"download_avg"` DownloadVar float32 `protobuf:"fixed32,15,opt,name=download_var,json=downloadVar,proto3" json:"download_var,omitempty" pg:"download_var"` Location *Location `protobuf:"bytes,16,opt,name=location,proto3" json:"location,omitempty" pg:"location"` StorageInfo *StorageInfo `protobuf:"bytes,17,opt,name=storage_info,json=storageInfo,proto3" json:"storage_info,omitempty" pg:"storage_info"` BandwidthInfo *BandwidthInfo `protobuf:"bytes,18,opt,name=bandwidth_info,json=bandwidthInfo,proto3" json:"bandwidth_info,omitempty" pg:"bandwidth_info"` CollateralInfo *CollateralInfo `protobuf:"bytes,19,opt,name=collateral_info,json=collateralInfo,proto3" json:"collateral_info,omitempty" pg:"collateral_info"` XXX_NoUnkeyedLiteral struct{} `json:"-" pg:"-"` XXX_unrecognized []byte `json:"-" pg:"-"` XXX_sizecache int32 `json:"-" pg:"-"` }
func (*Host) Descriptor ¶
func (*Host) GetBandwidthInfo ¶
func (m *Host) GetBandwidthInfo() *BandwidthInfo
func (*Host) GetBtfsVersion ¶
func (*Host) GetCollateralInfo ¶
func (m *Host) GetCollateralInfo() *CollateralInfo
func (*Host) GetDownloadAvg ¶
func (*Host) GetDownloadVar ¶
func (*Host) GetHeartBeats ¶
func (*Host) GetLocation ¶
func (*Host) GetReputation ¶
func (*Host) GetStorageInfo ¶
func (m *Host) GetStorageInfo() *StorageInfo
func (*Host) GetTimeCreate ¶
func (*Host) GetTimeUpdate ¶
func (*Host) GetUploadAvg ¶
func (*Host) GetUploadVar ¶
func (*Host) ProtoMessage ¶
func (*Host) ProtoMessage()
func (*Host) XXX_DiscardUnknown ¶
func (m *Host) XXX_DiscardUnknown()
func (*Host) XXX_MessageName ¶
func (*Host) XXX_Unmarshal ¶
type HostsClient ¶
type HostsClient interface {
GetHosts(ctx context.Context, in *HostsReq, opts ...grpc.CallOption) (*HostsResp, error)
}
HostsClient is the client API for Hosts service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewHostsClient ¶
func NewHostsClient(cc *grpc.ClientConn) HostsClient
type HostsData ¶
type HostsData struct { Hosts []*Host `protobuf:"bytes,1,rep,name=hosts,proto3" json:"hosts,omitempty" pg:"hosts"` XXX_NoUnkeyedLiteral struct{} `json:"-" pg:"-"` XXX_unrecognized []byte `json:"-" pg:"-"` XXX_sizecache int32 `json:"-" pg:"-"` }
func (*HostsData) Descriptor ¶
func (*HostsData) MarshalToSizedBuffer ¶
func (*HostsData) ProtoMessage ¶
func (*HostsData) ProtoMessage()
func (*HostsData) XXX_DiscardUnknown ¶
func (m *HostsData) XXX_DiscardUnknown()
func (*HostsData) XXX_Marshal ¶
func (*HostsData) XXX_MessageName ¶
func (*HostsData) XXX_Unmarshal ¶
type HostsReq ¶
type HostsReq struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty" pg:"id"` RespSize int32 `protobuf:"varint,2,opt,name=resp_size,json=respSize,proto3" json:"resp_size,omitempty" pg:"resp_size"` XXX_NoUnkeyedLiteral struct{} `json:"-" pg:"-"` XXX_unrecognized []byte `json:"-" pg:"-"` XXX_sizecache int32 `json:"-" pg:"-"` }
func (*HostsReq) Descriptor ¶
func (*HostsReq) GetRespSize ¶
func (*HostsReq) MarshalToSizedBuffer ¶
func (*HostsReq) ProtoMessage ¶
func (*HostsReq) ProtoMessage()
func (*HostsReq) XXX_DiscardUnknown ¶
func (m *HostsReq) XXX_DiscardUnknown()
func (*HostsReq) XXX_Marshal ¶
func (*HostsReq) XXX_MessageName ¶
func (*HostsReq) XXX_Unmarshal ¶
type HostsResp ¶
type HostsResp struct { Code ResponseCode `protobuf:"varint,1,opt,name=code,proto3,enum=hub.ResponseCode" json:"code,omitempty" pg:"code"` Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty" pg:"message"` Hosts *HostsData `protobuf:"bytes,3,opt,name=hosts,proto3" json:"hosts,omitempty" pg:"hosts"` RespSize int32 `protobuf:"varint,4,opt,name=resp_size,json=respSize,proto3" json:"resp_size,omitempty" pg:"resp_size"` Mode string `protobuf:"bytes,5,opt,name=mode,proto3" json:"mode,omitempty" pg:"mode"` ResponseTime time.Time `protobuf:"bytes,6,opt,name=response_time,json=responseTime,proto3,stdtime" json:"response_time" pg:"response_time"` XXX_NoUnkeyedLiteral struct{} `json:"-" pg:"-"` XXX_unrecognized []byte `json:"-" pg:"-"` XXX_sizecache int32 `json:"-" pg:"-"` }
func (*HostsResp) Descriptor ¶
func (*HostsResp) GetCode ¶
func (m *HostsResp) GetCode() ResponseCode
func (*HostsResp) GetMessage ¶
func (*HostsResp) GetRespSize ¶
func (*HostsResp) GetResponseTime ¶
func (*HostsResp) MarshalToSizedBuffer ¶
func (*HostsResp) ProtoMessage ¶
func (*HostsResp) ProtoMessage()
func (*HostsResp) XXX_DiscardUnknown ¶
func (m *HostsResp) XXX_DiscardUnknown()
func (*HostsResp) XXX_Marshal ¶
func (*HostsResp) XXX_MessageName ¶
func (*HostsResp) XXX_Unmarshal ¶
type HostsServer ¶
HostsServer is the server API for Hosts service.
type Location ¶
type Location struct { Lat float64 `protobuf:"fixed64,1,opt,name=lat,proto3" json:"lat,omitempty" pg:"lat"` Lon float64 `protobuf:"fixed64,2,opt,name=lon,proto3" json:"lon,omitempty" pg:"lon"` XXX_NoUnkeyedLiteral struct{} `json:"-" pg:"-"` XXX_unrecognized []byte `json:"-" pg:"-"` XXX_sizecache int32 `json:"-" pg:"-"` }
func (*Location) Descriptor ¶
func (*Location) MarshalToSizedBuffer ¶
func (*Location) ProtoMessage ¶
func (*Location) ProtoMessage()
func (*Location) XXX_DiscardUnknown ¶
func (m *Location) XXX_DiscardUnknown()
func (*Location) XXX_Marshal ¶
func (*Location) XXX_MessageName ¶
func (*Location) XXX_Unmarshal ¶
type ResponseCode ¶
type ResponseCode int32
const ( ResponseCode_SUCCESS ResponseCode = 0 ResponseCode_SIGNATURE_FORMAT_ERROR ResponseCode = 1 ResponseCode_COMPUTE_ADDRESS_ERROR ResponseCode = 2 ResponseCode_OTHER_ERROR ResponseCode = 20 )
func (ResponseCode) EnumDescriptor ¶
func (ResponseCode) EnumDescriptor() ([]byte, []int)
func (ResponseCode) String ¶
func (x ResponseCode) String() string
type SettingsClient ¶
type SettingsClient interface {
GetSettings(ctx context.Context, in *SettingsReq, opts ...grpc.CallOption) (*SettingsResp, error)
}
SettingsClient is the client API for Settings service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewSettingsClient ¶
func NewSettingsClient(cc *grpc.ClientConn) SettingsClient
type SettingsData ¶
type SettingsData struct { StoragePriceAsk float64 `` /* 133-byte string literal not displayed */ BandwidthPriceAsk float64 `` /* 141-byte string literal not displayed */ StorageTimeMin float64 `` /* 129-byte string literal not displayed */ BandwidthLimit float64 `` /* 126-byte string literal not displayed */ CollateralStake float64 `` /* 130-byte string literal not displayed */ XXX_NoUnkeyedLiteral struct{} `json:"-" pg:"-"` XXX_unrecognized []byte `json:"-" pg:"-"` XXX_sizecache int32 `json:"-" pg:"-"` }
func (*SettingsData) Descriptor ¶
func (*SettingsData) Descriptor() ([]byte, []int)
func (*SettingsData) GetBandwidthLimit ¶
func (m *SettingsData) GetBandwidthLimit() float64
func (*SettingsData) GetBandwidthPriceAsk ¶
func (m *SettingsData) GetBandwidthPriceAsk() float64
func (*SettingsData) GetCollateralStake ¶
func (m *SettingsData) GetCollateralStake() float64
func (*SettingsData) GetStoragePriceAsk ¶
func (m *SettingsData) GetStoragePriceAsk() float64
func (*SettingsData) GetStorageTimeMin ¶
func (m *SettingsData) GetStorageTimeMin() float64
func (*SettingsData) Marshal ¶
func (m *SettingsData) Marshal() (dAtA []byte, err error)
func (*SettingsData) MarshalToSizedBuffer ¶
func (m *SettingsData) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*SettingsData) ProtoMessage ¶
func (*SettingsData) ProtoMessage()
func (*SettingsData) Reset ¶
func (m *SettingsData) Reset()
func (*SettingsData) Size ¶
func (m *SettingsData) Size() (n int)
func (*SettingsData) String ¶
func (m *SettingsData) String() string
func (*SettingsData) Unmarshal ¶
func (m *SettingsData) Unmarshal(dAtA []byte) error
func (*SettingsData) XXX_DiscardUnknown ¶
func (m *SettingsData) XXX_DiscardUnknown()
func (*SettingsData) XXX_Marshal ¶
func (m *SettingsData) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SettingsData) XXX_Merge ¶
func (m *SettingsData) XXX_Merge(src proto.Message)
func (*SettingsData) XXX_MessageName ¶
func (*SettingsData) XXX_MessageName() string
func (*SettingsData) XXX_Size ¶
func (m *SettingsData) XXX_Size() int
func (*SettingsData) XXX_Unmarshal ¶
func (m *SettingsData) XXX_Unmarshal(b []byte) error
type SettingsReq ¶
type SettingsReq struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty" pg:"id"` RespSize int32 `protobuf:"varint,2,opt,name=resp_size,json=respSize,proto3" json:"resp_size,omitempty" pg:"resp_size"` XXX_NoUnkeyedLiteral struct{} `json:"-" pg:"-"` XXX_unrecognized []byte `json:"-" pg:"-"` XXX_sizecache int32 `json:"-" pg:"-"` }
func (*SettingsReq) Descriptor ¶
func (*SettingsReq) Descriptor() ([]byte, []int)
func (*SettingsReq) GetId ¶
func (m *SettingsReq) GetId() string
func (*SettingsReq) GetRespSize ¶
func (m *SettingsReq) GetRespSize() int32
func (*SettingsReq) Marshal ¶
func (m *SettingsReq) Marshal() (dAtA []byte, err error)
func (*SettingsReq) MarshalToSizedBuffer ¶
func (m *SettingsReq) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*SettingsReq) ProtoMessage ¶
func (*SettingsReq) ProtoMessage()
func (*SettingsReq) Reset ¶
func (m *SettingsReq) Reset()
func (*SettingsReq) Size ¶
func (m *SettingsReq) Size() (n int)
func (*SettingsReq) String ¶
func (m *SettingsReq) String() string
func (*SettingsReq) Unmarshal ¶
func (m *SettingsReq) Unmarshal(dAtA []byte) error
func (*SettingsReq) XXX_DiscardUnknown ¶
func (m *SettingsReq) XXX_DiscardUnknown()
func (*SettingsReq) XXX_Marshal ¶
func (m *SettingsReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SettingsReq) XXX_Merge ¶
func (m *SettingsReq) XXX_Merge(src proto.Message)
func (*SettingsReq) XXX_MessageName ¶
func (*SettingsReq) XXX_MessageName() string
func (*SettingsReq) XXX_Size ¶
func (m *SettingsReq) XXX_Size() int
func (*SettingsReq) XXX_Unmarshal ¶
func (m *SettingsReq) XXX_Unmarshal(b []byte) error
type SettingsResp ¶
type SettingsResp struct { Code ResponseCode `protobuf:"varint,1,opt,name=code,proto3,enum=hub.ResponseCode" json:"code,omitempty" pg:"code"` Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty" pg:"message"` ResponseTime time.Time `protobuf:"bytes,3,opt,name=response_time,json=responseTime,proto3,stdtime" json:"response_time" pg:"response_time"` SettingsData *SettingsData `protobuf:"bytes,4,opt,name=settings_data,json=settingsData,proto3" json:"settings_data,omitempty" pg:"settings_data"` XXX_NoUnkeyedLiteral struct{} `json:"-" pg:"-"` XXX_unrecognized []byte `json:"-" pg:"-"` XXX_sizecache int32 `json:"-" pg:"-"` }
func (*SettingsResp) Descriptor ¶
func (*SettingsResp) Descriptor() ([]byte, []int)
func (*SettingsResp) GetCode ¶
func (m *SettingsResp) GetCode() ResponseCode
func (*SettingsResp) GetMessage ¶
func (m *SettingsResp) GetMessage() string
func (*SettingsResp) GetResponseTime ¶
func (m *SettingsResp) GetResponseTime() time.Time
func (*SettingsResp) GetSettingsData ¶
func (m *SettingsResp) GetSettingsData() *SettingsData
func (*SettingsResp) Marshal ¶
func (m *SettingsResp) Marshal() (dAtA []byte, err error)
func (*SettingsResp) MarshalToSizedBuffer ¶
func (m *SettingsResp) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*SettingsResp) ProtoMessage ¶
func (*SettingsResp) ProtoMessage()
func (*SettingsResp) Reset ¶
func (m *SettingsResp) Reset()
func (*SettingsResp) Size ¶
func (m *SettingsResp) Size() (n int)
func (*SettingsResp) String ¶
func (m *SettingsResp) String() string
func (*SettingsResp) Unmarshal ¶
func (m *SettingsResp) Unmarshal(dAtA []byte) error
func (*SettingsResp) XXX_DiscardUnknown ¶
func (m *SettingsResp) XXX_DiscardUnknown()
func (*SettingsResp) XXX_Marshal ¶
func (m *SettingsResp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SettingsResp) XXX_Merge ¶
func (m *SettingsResp) XXX_Merge(src proto.Message)
func (*SettingsResp) XXX_MessageName ¶
func (*SettingsResp) XXX_MessageName() string
func (*SettingsResp) XXX_Size ¶
func (m *SettingsResp) XXX_Size() int
func (*SettingsResp) XXX_Unmarshal ¶
func (m *SettingsResp) XXX_Unmarshal(b []byte) error
type SettingsServer ¶
type SettingsServer interface {
GetSettings(context.Context, *SettingsReq) (*SettingsResp, error)
}
SettingsServer is the server API for Settings service.
type StorageInfo ¶
type StorageInfo struct { StorageCap float32 `protobuf:"fixed32,1,opt,name=storage_cap,json=storageCap,proto3" json:"storage_cap,omitempty" pg:"storage_cap"` StorageLeft float32 `protobuf:"fixed32,2,opt,name=storage_left,json=storageLeft,proto3" json:"storage_left,omitempty" pg:"storage_left"` StorageMinTime int64 `` /* 128-byte string literal not displayed */ StorageAskPrice float32 `` /* 133-byte string literal not displayed */ StoragePriceEst float32 `` /* 133-byte string literal not displayed */ XXX_NoUnkeyedLiteral struct{} `json:"-" pg:"-"` XXX_unrecognized []byte `json:"-" pg:"-"` XXX_sizecache int32 `json:"-" pg:"-"` }
func (*StorageInfo) Descriptor ¶
func (*StorageInfo) Descriptor() ([]byte, []int)
func (*StorageInfo) GetStorageAskPrice ¶
func (m *StorageInfo) GetStorageAskPrice() float32
func (*StorageInfo) GetStorageCap ¶
func (m *StorageInfo) GetStorageCap() float32
func (*StorageInfo) GetStorageLeft ¶
func (m *StorageInfo) GetStorageLeft() float32
func (*StorageInfo) GetStorageMinTime ¶
func (m *StorageInfo) GetStorageMinTime() int64
func (*StorageInfo) GetStoragePriceEst ¶
func (m *StorageInfo) GetStoragePriceEst() float32
func (*StorageInfo) Marshal ¶
func (m *StorageInfo) Marshal() (dAtA []byte, err error)
func (*StorageInfo) MarshalToSizedBuffer ¶
func (m *StorageInfo) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*StorageInfo) ProtoMessage ¶
func (*StorageInfo) ProtoMessage()
func (*StorageInfo) Reset ¶
func (m *StorageInfo) Reset()
func (*StorageInfo) Size ¶
func (m *StorageInfo) Size() (n int)
func (*StorageInfo) String ¶
func (m *StorageInfo) String() string
func (*StorageInfo) Unmarshal ¶
func (m *StorageInfo) Unmarshal(dAtA []byte) error
func (*StorageInfo) XXX_DiscardUnknown ¶
func (m *StorageInfo) XXX_DiscardUnknown()
func (*StorageInfo) XXX_Marshal ¶
func (m *StorageInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*StorageInfo) XXX_Merge ¶
func (m *StorageInfo) XXX_Merge(src proto.Message)
func (*StorageInfo) XXX_MessageName ¶
func (*StorageInfo) XXX_MessageName() string
func (*StorageInfo) XXX_Size ¶
func (m *StorageInfo) XXX_Size() int
func (*StorageInfo) XXX_Unmarshal ¶
func (m *StorageInfo) XXX_Unmarshal(b []byte) error
type UnimplementedHostsServer ¶
type UnimplementedHostsServer struct { }
UnimplementedHostsServer can be embedded to have forward compatible implementations.
type UnimplementedSettingsServer ¶
type UnimplementedSettingsServer struct { }
UnimplementedSettingsServer can be embedded to have forward compatible implementations.
func (*UnimplementedSettingsServer) GetSettings ¶
func (*UnimplementedSettingsServer) GetSettings(ctx context.Context, req *SettingsReq) (*SettingsResp, error)
Click to show internal directories.
Click to hide internal directories.