# Functions
AddContext wraps an error in a context.
CalculateLeaves calculates the number of leaves that would be pushed from data of size 'dataSize'.
CheckGouging performs a number of gouging checks before forming a contract with the host.
ComposeErrors combines several errors in one.
ContainsError checks if one error contains the other.
CopyTransaction creates a deep copy of the transaction.
DecodeAnnouncement decodes announcement bytes into a host announcement, verifying the prefix and the signature.
DecodeV2Announcement verifies a V2 host announcement against the signature.
DeriveAccountKey derives an account key to be used by the renter to access the ephemeral account at the host.
DeriveEphemeralKey derives a secret key to be used by the renter for the exchange with the host.
DeriveRenterKey derives a key to be used by the renter for accessing the file contracts.
EncodedLen returns the encoded length of a transaction.
FilesizeUnits returns a string that displays a filesize in human-readable units.
Float64 converts types.Currency to float64.
FromFloat converts f Siacoins to a types.Currency value.
GenerateKeyPair generates a private/public keypair from a seed.
KeyFromSeed returns the Ed25519 key derived from the supplied seed at the specified index.
MulFloat multiplies a types.Currency by a float64 value.
NewSeedPhrase returns a random seed phrase.
NewTree returns a MerkleTree, which can be used for getting Merkle roots and Merkle proofs on data.
PeekErr checks if a chan error has an error waiting to be returned.
PostTax returns the amount of currency remaining in a file contract payout after tax.
ReadCurrency converts a string to types.Currency.
RenterPayoutsPreTax calculates the renterPayout before tax and the hostPayout given a host, the available renter funding, the expected txnFee for the transaction and an optional basePrice in case this helper is used for a renewal.
SeedFromPhrase converts the supplied phrase into a 16-byte seed.
Tax calculates the Siafund fee from the amount.
ToString formats a types.Currency to a maximum of 2 decimal places.
VerifyRangeProof verifies a proof produced by MerkleRangeProof.
VerifySegment will verify that a segment, given the proof, is a part of a Merkle root.
# Constants
BlocksPerDay is the number of blocks expected to be mined per day.
BlocksPerHour is the number of blocks expected to be mined per hour.
BlocksPerMonth is the number of blocks expected to be mined per month.
BlocksPerWeek is the number of blocks expected to be mined per week.
BlocksPerYear is the number of blocks expected to be mined per year.
BytesPerTerabyte is how many bytes are there in one TiB.
HostDBFilterError HostDBDisableFilter HostDBActivateBlacklist and HostDBActiveWhitelist are the constants used to enable and disable the filter mode of the manager's hostdb.
HostDBFilterError HostDBDisableFilter HostDBActivateBlacklist and HostDBActiveWhitelist are the constants used to enable and disable the filter mode of the manager's hostdb.
HostDBFilterError HostDBDisableFilter HostDBActivateBlacklist and HostDBActiveWhitelist are the constants used to enable and disable the filter mode of the manager's hostdb.
HostDBFilterError HostDBDisableFilter HostDBActivateBlacklist and HostDBActiveWhitelist are the constants used to enable and disable the filter mode of the manager's hostdb.
MaxEncodedNetAddressLength is the maximum length of a NetAddress encoded with the encode package.
MinMessageSize is the minimum size of an RPC message.
OnHoldThreshold is how much time shall pass until we put the account in pre-payment mode.
SegmentSize is the chunk size that is used when taking the Merkle root of a file.
# Variables
BlockBytesPerMonthTerabyte is the conversion rate between block-bytes and month-TB.
DefaultAllowance is the set of default allowance settings that will be used when allowances are not set or not fully set.
DefaultPricing provides some default prices if none are set.
ErrInsufficientBalance is returned when there aren't enough unused outputs to cover the requested amount.
MaxRPCPrice is how much the Satellite is willing to pay for a single RPC call.
MaxSectorAccessPrice is how much the Satellite is willing to pay to download a single sector.
StaticPricing keeps the current prices.
# Structs
An Allowance dictates how much the renter is allowed to spend in a given period.
BucketFiles contains a list of filepaths within a single bucket.
ContractMetadata contains all metadata needed to re-create a contract.
ContractUtility contains metrics internal to the contractor that reflect the utility of a given contract.
ContractWatchStatus provides information about the status of a contract in the manager's watchdog.
CreditData contains the information about any running promotion.
ExtendedContract contains the contract and its metadata.
ExtendedContractSet is a collection of extendedContracts.
FileMetadata contains the uploaded file metadata.
HostAverages contains the host network averages from HostDB.
A HostDBEntry represents one host entry in the Manager's host DB.
HostDBScan represents a single scan event.
HostScoreBreakdown breaks down the host scores.
MaintenanceSpending is a helper struct that contains a breakdown of costs related to the maintenance (a.k.a upkeep) of the RHP3 protocol.
MerkleTree wraps merkletree.Tree, changing some of the function definitions to assume sia-specific constants and return sia-specific types.
A PoolTransaction summarizes the wallet-relevant data in a txpool transaction.
No description provided by the author
No description provided by the author
Renter holds the data related to the specific renter.
A RenterContract contains metadata about a file contract.
RenterSettings keep the opt-in settings of the renter.
RenterSpending contains the metrics about how much the renter has spent during the current billing period.
RPCError is the generic error transferred in an RPC.
RPCResponse if a helper type for encoding and decoding RPC response messages, which can represent either valid data or an error.
An RPCSession contains the state of an RPC session with a renter.
Shard represents an individual shard.
Slab is a collection of shards.
SpendingDetails is a helper struct that contains a breakdown of where exactly the money was spent.
UserBalance holds the current balance as well as the data on the chosen payment scheme.
UserSpendings contains the spendings in the current and the previous months.
# Interfaces
A HostDB is a database of hosts that the manager can use for figuring out who to upload to, and download from.
Manager implements the methods necessary to communicate with the hosts.
Portal implements the portal server.
Provider implements the methods necessary to communicate with the renters.
RequestBody is the common interface type for the renter requests.
A Syncer synchronizes blockchain data with peers.
Wallet stores and manages Siacoins.
# Type aliases
FilterMode is the helper type for the enum constants for the HostDB filter mode.
HostDBScans represents a sortable slice of scans.
A NetAddress contains the information needed to contact a peer.
Seed represents a 16-byte wallet seed.