Documentation ¶
Index ¶
- type PaychAPI
- func (a *PaychAPI) PaychAllocateLane(ctx context.Context, ch address.Address) (uint64, error)
- func (a *PaychAPI) PaychAvailableFunds(ctx context.Context, ch address.Address) (*types.ChannelAvailableFunds, error)
- func (a *PaychAPI) PaychAvailableFundsByFromTo(ctx context.Context, from, to address.Address) (*types.ChannelAvailableFunds, error)
- func (a *PaychAPI) PaychCollect(ctx context.Context, addr address.Address) (cid.Cid, error)
- func (a *PaychAPI) PaychFund(ctx context.Context, from, to address.Address, amt types.BigInt) (*types.ChannelInfo, error)
- func (a *PaychAPI) PaychGet(ctx context.Context, from, to address.Address, amt types.BigInt, ...) (*types.ChannelInfo, error)
- func (a *PaychAPI) PaychGetWaitReady(ctx context.Context, sentinel cid.Cid) (address.Address, error)
- func (a *PaychAPI) PaychList(ctx context.Context) ([]address.Address, error)
- func (a *PaychAPI) PaychNewPayment(ctx context.Context, from, to address.Address, vouchers []types.VoucherSpec) (*types.PaymentInfo, error)
- func (a *PaychAPI) PaychSettle(ctx context.Context, addr address.Address) (cid.Cid, error)
- func (a *PaychAPI) PaychStatus(ctx context.Context, pch address.Address) (*types.Status, error)
- func (a *PaychAPI) PaychVoucherAdd(ctx context.Context, ch address.Address, sv *paych.SignedVoucher, proof []byte, ...) (big.Int, error)
- func (a *PaychAPI) PaychVoucherCheckSpendable(ctx context.Context, ch address.Address, sv *paych.SignedVoucher, ...) (bool, error)
- func (a *PaychAPI) PaychVoucherCheckValid(ctx context.Context, ch address.Address, sv *paych.SignedVoucher) error
- func (a *PaychAPI) PaychVoucherCreate(ctx context.Context, pch address.Address, amt big.Int, lane uint64) (*types.VoucherCreateResult, error)
- func (a *PaychAPI) PaychVoucherList(ctx context.Context, pch address.Address) ([]*paych.SignedVoucher, error)
- func (a *PaychAPI) PaychVoucherSubmit(ctx context.Context, ch address.Address, sv *paych.SignedVoucher, ...) (cid.Cid, error)
- type PaychSubmodule
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PaychAPI ¶ added in v1.1.0
type PaychAPI struct {
// contains filtered or unexported fields
}
func NewPaychAPI ¶ added in v1.1.0
func (*PaychAPI) PaychAllocateLane ¶ added in v1.1.0
func (*PaychAPI) PaychAvailableFunds ¶ added in v1.1.0
func (*PaychAPI) PaychAvailableFundsByFromTo ¶ added in v1.1.0
func (*PaychAPI) PaychCollect ¶ added in v1.1.0
func (*PaychAPI) PaychGet ¶ added in v1.1.0
func (a *PaychAPI) PaychGet(ctx context.Context, from, to address.Address, amt types.BigInt, opts types.PaychGetOpts) (*types.ChannelInfo, error)
func (*PaychAPI) PaychGetWaitReady ¶ added in v1.1.0
func (*PaychAPI) PaychNewPayment ¶ added in v1.1.0
func (a *PaychAPI) PaychNewPayment(ctx context.Context, from, to address.Address, vouchers []types.VoucherSpec) (*types.PaymentInfo, error)
func (*PaychAPI) PaychSettle ¶ added in v1.1.0
func (*PaychAPI) PaychStatus ¶ added in v1.1.0
func (*PaychAPI) PaychVoucherAdd ¶ added in v1.1.0
func (*PaychAPI) PaychVoucherCheckSpendable ¶ added in v1.1.0
func (*PaychAPI) PaychVoucherCheckValid ¶ added in v1.1.0
func (*PaychAPI) PaychVoucherCreate ¶ added in v1.1.0
func (a *PaychAPI) PaychVoucherCreate(ctx context.Context, pch address.Address, amt big.Int, lane uint64) (*types.VoucherCreateResult, error)
PaychVoucherCreate creates a new signed voucher on the given payment channel with the given lane and amount. The value passed in is exactly the value that will be used to create the voucher, so if previous vouchers exist, the actual additional value of this voucher will only be the difference between the two. If there are insufficient funds in the channel to create the voucher, returns a nil voucher and the shortfall.
func (*PaychAPI) PaychVoucherList ¶ added in v1.1.0
func (*PaychAPI) PaychVoucherSubmit ¶ added in v1.1.0
type PaychSubmodule ¶
type PaychSubmodule struct {
// contains filtered or unexported fields
}
PaychSubmodule support paych related functions, including paych construction, extraction, query and other functions
func NewPaychSubmodule ¶
func NewPaychSubmodule(ctx context.Context, ds datastore.Batching, params *paychmgr.ManagerParams) (*PaychSubmodule, error)
PaychSubmodule enhances the `Node` with paych capabilities.
func (*PaychSubmodule) API ¶
func (ps *PaychSubmodule) API() v1api.IPaychan
API create a new paych implement
func (*PaychSubmodule) Stop ¶
func (ps *PaychSubmodule) Stop()
func (*PaychSubmodule) V0API ¶ added in v0.9.7
func (ps *PaychSubmodule) V0API() v0api.IPaychan