Documentation ¶
Index ¶
- Constants
- func MakeCid(data []byte) (string, error)
- func MakeFid(data []byte) (string, error)
- func NewMsgServerImpl(keeper Keeper) types.MsgServer
- type Keeper
- func (k Keeper) ActiveDeals(c context.Context, req *types.QueryGetActiveDealsRequest) (*types.QueryGetActiveDealsResponse, error)
- func (k Keeper) ActiveDealsAll(c context.Context, req *types.QueryAllActiveDealsRequest) (*types.QueryAllActiveDealsResponse, error)
- func (k Keeper) ClientUsage(c context.Context, req *types.QueryGetClientUsageRequest) (*types.QueryGetClientUsageResponse, error)
- func (k Keeper) ClientUsageAll(c context.Context, req *types.QueryAllClientUsageRequest) (*types.QueryAllClientUsageResponse, error)
- func (k Keeper) Contracts(c context.Context, req *types.QueryGetContractsRequest) (*types.QueryGetContractsResponse, error)
- func (k Keeper) ContractsAll(c context.Context, req *types.QueryAllContractsRequest) (*types.QueryAllContractsResponse, error)
- func (k Keeper) CreatePayBlock(ctx sdk.Context, address string, length int64, bytes int64) error
- func (k Keeper) FidCid(c context.Context, req *types.QueryGetFidCidRequest) (*types.QueryGetFidCidResponse, error)
- func (k Keeper) FidCidAll(c context.Context, req *types.QueryAllFidCidRequest) (*types.QueryAllFidCidResponse, error)
- func (k Keeper) FindFile(goCtx context.Context, req *types.QueryFindFileRequest) (*types.QueryFindFileResponse, error)
- func (k Keeper) Freespace(goCtx context.Context, req *types.QueryFreespaceRequest) (*types.QueryFreespaceResponse, error)
- func (k Keeper) GetActiveDeals(ctx sdk.Context, cid string) (val types.ActiveDeals, found bool)
- func (k Keeper) GetAllActiveDeals(ctx sdk.Context) (list []types.ActiveDeals)
- func (k Keeper) GetAllClientUsage(ctx sdk.Context) (list []types.ClientUsage)
- func (k Keeper) GetAllContracts(ctx sdk.Context) (list []types.Contracts)
- func (k Keeper) GetAllFidCid(ctx sdk.Context) (list []types.FidCid)
- func (k Keeper) GetAllPayBlocks(ctx sdk.Context) (list []types.PayBlocks)
- func (k Keeper) GetAllProviders(ctx sdk.Context) (list []types.Providers)
- func (k Keeper) GetAllStrays(ctx sdk.Context) (list []types.Strays)
- func (k Keeper) GetClientFreeSpace(goCtx context.Context, req *types.QueryGetClientFreeSpaceRequest) (*types.QueryGetClientFreeSpaceResponse, error)
- func (k Keeper) GetClientUsage(ctx sdk.Context, address string) (val types.ClientUsage, found bool)
- func (k Keeper) GetContracts(ctx sdk.Context, cid string) (val types.Contracts, found bool)
- func (k Keeper) GetFidCid(ctx sdk.Context, fid string) (val types.FidCid, found bool)
- func (k Keeper) GetPaidAmount(ctx sdk.Context, address string, blockh int64) (int64, bool, *types.PayBlocks)
- func (k Keeper) GetParams(ctx sdk.Context) types.Params
- func (k Keeper) GetPayBlocks(ctx sdk.Context, blockid string) (val types.PayBlocks, found bool)
- func (k Keeper) GetPayData(goCtx context.Context, req *types.QueryGetPayDataRequest) (*types.QueryGetPayDataResponse, error)
- func (k Keeper) GetProviderUsing(ctx sdk.Context, provider string) int64
- func (k Keeper) GetProviders(ctx sdk.Context, address string) (val types.Providers, found bool)
- func (k Keeper) GetStrays(ctx sdk.Context, cid string) (val types.Strays, found bool)
- func (k Keeper) HandleBlock(ctx sdk.Context)
- func (k Keeper) ListFiles(ctx sdk.Context, fid string) []string
- func (k Keeper) Logger(ctx sdk.Context) log.Logger
- func (k Keeper) Params(c context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
- func (k Keeper) PayBlocks(c context.Context, req *types.QueryGetPayBlocksRequest) (*types.QueryGetPayBlocksResponse, error)
- func (k Keeper) PayBlocksAll(c context.Context, req *types.QueryAllPayBlocksRequest) (*types.QueryAllPayBlocksResponse, error)
- func (k Keeper) Providers(c context.Context, req *types.QueryGetProvidersRequest) (*types.QueryGetProvidersResponse, error)
- func (k Keeper) ProvidersAll(c context.Context, req *types.QueryAllProvidersRequest) (*types.QueryAllProvidersResponse, error)
- func (k Keeper) RemoveActiveDeals(ctx sdk.Context, cid string)
- func (k Keeper) RemoveClientUsage(ctx sdk.Context, address string)
- func (k Keeper) RemoveContracts(ctx sdk.Context, cid string)
- func (k Keeper) RemoveFidCid(ctx sdk.Context, fid string)
- func (k Keeper) RemovePayBlocks(ctx sdk.Context, blockid string)
- func (k Keeper) RemoveProviders(ctx sdk.Context, address string)
- func (k Keeper) RemoveStrays(ctx sdk.Context, cid string)
- func (k Keeper) SetActiveDeals(ctx sdk.Context, activeDeals types.ActiveDeals)
- func (k Keeper) SetClientUsage(ctx sdk.Context, clientUsage types.ClientUsage)
- func (k Keeper) SetContracts(ctx sdk.Context, contracts types.Contracts)
- func (k Keeper) SetFidCid(ctx sdk.Context, fidCid types.FidCid)
- func (k Keeper) SetParams(ctx sdk.Context, params types.Params)
- func (k Keeper) SetPayBlocks(ctx sdk.Context, payBlocks types.PayBlocks)
- func (k Keeper) SetProviders(ctx sdk.Context, providers types.Providers)
- func (k Keeper) SetStrays(ctx sdk.Context, strays types.Strays)
- func (k Keeper) Strays(c context.Context, req *types.QueryGetStraysRequest) (*types.QueryGetStraysResponse, error)
- func (k Keeper) StraysAll(c context.Context, req *types.QueryAllStraysRequest) (*types.QueryAllStraysResponse, error)
Constants ¶
const ( StartBlockType = "start" EndBlockType = "end" TwoGigs = 2000000000 )
Variables ¶
This section is empty.
Functions ¶
func NewMsgServerImpl ¶
NewMsgServerImpl returns an implementation of the MsgServer interface for the provided Keeper.
Types ¶
type Keeper ¶
type Keeper struct {
// contains filtered or unexported fields
}
func NewKeeper ¶
func NewKeeper( cdc codec.BinaryCodec, storeKey, memKey sdk.StoreKey, ps paramtypes.Subspace, bankkeeper types.BankKeeper, accountkeeper types.AccountKeeper, ) *Keeper
func (Keeper) ActiveDeals ¶
func (k Keeper) ActiveDeals(c context.Context, req *types.QueryGetActiveDealsRequest) (*types.QueryGetActiveDealsResponse, error)
func (Keeper) ActiveDealsAll ¶
func (k Keeper) ActiveDealsAll(c context.Context, req *types.QueryAllActiveDealsRequest) (*types.QueryAllActiveDealsResponse, error)
func (Keeper) ClientUsage ¶
func (k Keeper) ClientUsage(c context.Context, req *types.QueryGetClientUsageRequest) (*types.QueryGetClientUsageResponse, error)
func (Keeper) ClientUsageAll ¶
func (k Keeper) ClientUsageAll(c context.Context, req *types.QueryAllClientUsageRequest) (*types.QueryAllClientUsageResponse, error)
func (Keeper) Contracts ¶
func (k Keeper) Contracts(c context.Context, req *types.QueryGetContractsRequest) (*types.QueryGetContractsResponse, error)
func (Keeper) ContractsAll ¶
func (k Keeper) ContractsAll(c context.Context, req *types.QueryAllContractsRequest) (*types.QueryAllContractsResponse, error)
func (Keeper) CreatePayBlock ¶
func (Keeper) FidCid ¶
func (k Keeper) FidCid(c context.Context, req *types.QueryGetFidCidRequest) (*types.QueryGetFidCidResponse, error)
func (Keeper) FidCidAll ¶
func (k Keeper) FidCidAll(c context.Context, req *types.QueryAllFidCidRequest) (*types.QueryAllFidCidResponse, error)
func (Keeper) FindFile ¶
func (k Keeper) FindFile(goCtx context.Context, req *types.QueryFindFileRequest) (*types.QueryFindFileResponse, error)
func (Keeper) Freespace ¶
func (k Keeper) Freespace(goCtx context.Context, req *types.QueryFreespaceRequest) (*types.QueryFreespaceResponse, error)
func (Keeper) GetActiveDeals ¶
GetActiveDeals returns a activeDeals from its index
func (Keeper) GetAllActiveDeals ¶
func (k Keeper) GetAllActiveDeals(ctx sdk.Context) (list []types.ActiveDeals)
GetAllActiveDeals returns all activeDeals
func (Keeper) GetAllClientUsage ¶
func (k Keeper) GetAllClientUsage(ctx sdk.Context) (list []types.ClientUsage)
GetAllClientUsage returns all clientUsage
func (Keeper) GetAllContracts ¶
GetAllContracts returns all contracts
func (Keeper) GetAllFidCid ¶
GetAllFidCid returns all fidCid
func (Keeper) GetAllPayBlocks ¶
GetAllPayBlocks returns all payBlocks
func (Keeper) GetAllProviders ¶
GetAllProviders returns all providers
func (Keeper) GetAllStrays ¶
GetAllStrays returns all strays
func (Keeper) GetClientFreeSpace ¶
func (k Keeper) GetClientFreeSpace(goCtx context.Context, req *types.QueryGetClientFreeSpaceRequest) (*types.QueryGetClientFreeSpaceResponse, error)
func (Keeper) GetClientUsage ¶
func (k Keeper) GetClientUsage( ctx sdk.Context, address string, ) (val types.ClientUsage, found bool)
GetClientUsage returns a clientUsage from its index
func (Keeper) GetContracts ¶
GetContracts returns a contracts from its index
func (Keeper) GetPaidAmount ¶
func (Keeper) GetPayBlocks ¶
GetPayBlocks returns a payBlocks from its index
func (Keeper) GetPayData ¶
func (k Keeper) GetPayData(goCtx context.Context, req *types.QueryGetPayDataRequest) (*types.QueryGetPayDataResponse, error)
func (Keeper) GetProviderUsing ¶
func (Keeper) GetProviders ¶
GetProviders returns a providers from its index
func (Keeper) HandleBlock ¶
func (Keeper) Params ¶
func (k Keeper) Params(c context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
func (Keeper) PayBlocks ¶
func (k Keeper) PayBlocks(c context.Context, req *types.QueryGetPayBlocksRequest) (*types.QueryGetPayBlocksResponse, error)
func (Keeper) PayBlocksAll ¶
func (k Keeper) PayBlocksAll(c context.Context, req *types.QueryAllPayBlocksRequest) (*types.QueryAllPayBlocksResponse, error)
func (Keeper) Providers ¶
func (k Keeper) Providers(c context.Context, req *types.QueryGetProvidersRequest) (*types.QueryGetProvidersResponse, error)
func (Keeper) ProvidersAll ¶
func (k Keeper) ProvidersAll(c context.Context, req *types.QueryAllProvidersRequest) (*types.QueryAllProvidersResponse, error)
func (Keeper) RemoveActiveDeals ¶
RemoveActiveDeals removes a activeDeals from the store
func (Keeper) RemoveClientUsage ¶
RemoveClientUsage removes a clientUsage from the store
func (Keeper) RemoveContracts ¶
RemoveContracts removes a contracts from the store
func (Keeper) RemoveFidCid ¶
RemoveFidCid removes a fidCid from the store
func (Keeper) RemovePayBlocks ¶
RemovePayBlocks removes a payBlocks from the store
func (Keeper) RemoveProviders ¶
RemoveProviders removes a providers from the store
func (Keeper) RemoveStrays ¶
RemoveStrays removes a strays from the store
func (Keeper) SetActiveDeals ¶
func (k Keeper) SetActiveDeals(ctx sdk.Context, activeDeals types.ActiveDeals)
SetActiveDeals set a specific activeDeals in the store from its index
func (Keeper) SetClientUsage ¶
func (k Keeper) SetClientUsage(ctx sdk.Context, clientUsage types.ClientUsage)
SetClientUsage set a specific clientUsage in the store from its index
func (Keeper) SetContracts ¶
SetContracts set a specific contracts in the store from its index
func (Keeper) SetPayBlocks ¶
SetPayBlocks set a specific payBlocks in the store from its index
func (Keeper) SetProviders ¶
SetProviders set a specific providers in the store from its index
func (Keeper) Strays ¶
func (k Keeper) Strays(c context.Context, req *types.QueryGetStraysRequest) (*types.QueryGetStraysResponse, error)
func (Keeper) StraysAll ¶
func (k Keeper) StraysAll(c context.Context, req *types.QueryAllStraysRequest) (*types.QueryAllStraysResponse, error)
Source Files ¶
- active_deals.go
- client_usage.go
- contracts.go
- fid_cid.go
- grpc_query.go
- grpc_query_active_deals.go
- grpc_query_client_usage.go
- grpc_query_contracts.go
- grpc_query_fid_cid.go
- grpc_query_find_file.go
- grpc_query_freespace.go
- grpc_query_get_client_free_space.go
- grpc_query_get_pay_data.go
- grpc_query_params.go
- grpc_query_pay_blocks.go
- grpc_query_providers.go
- grpc_query_strays.go
- keeper.go
- msg_server.go
- msg_server_buy_storage.go
- msg_server_cancel_contract.go
- msg_server_claim_stray.go
- msg_server_init_provider.go
- msg_server_post_contract.go
- msg_server_postproof.go
- msg_server_set_provider_ip.go
- msg_server_set_provider_keybase.go
- msg_server_set_provider_totalspace.go
- msg_server_sign_contract.go
- params.go
- pay_blocks.go
- providers.go
- rewards.go
- strays.go
- utils.go