github.com/johnathanhowell/sia@v0.5.1-beta.0.20160524050156-83dcc3d37c94/modules/renter/proto/proto.go (about)

     1  package proto
     2  
     3  import (
     4  	"github.com/NebulousLabs/Sia/modules"
     5  	"github.com/NebulousLabs/Sia/types"
     6  )
     7  
     8  // dependencies
     9  type (
    10  	transactionBuilder interface {
    11  		AddFileContract(types.FileContract) uint64
    12  		AddMinerFee(types.Currency) uint64
    13  		AddParents([]types.Transaction)
    14  		AddSiacoinInput(types.SiacoinInput) uint64
    15  		AddSiacoinOutput(types.SiacoinOutput) uint64
    16  		AddTransactionSignature(types.TransactionSignature) uint64
    17  		FundSiacoins(types.Currency) error
    18  		Sign(bool) ([]types.Transaction, error)
    19  		View() (types.Transaction, []types.Transaction)
    20  		ViewAdded() (parents, coins, funds, signatures []int)
    21  	}
    22  
    23  	transactionPool interface {
    24  		AcceptTransactionSet([]types.Transaction) error
    25  		FeeEstimation() (min types.Currency, max types.Currency)
    26  	}
    27  )
    28  
    29  // ContractParams are supplied as an argument to FormContract.
    30  type ContractParams struct {
    31  	Host          modules.HostDBEntry
    32  	Filesize      uint64
    33  	StartHeight   types.BlockHeight
    34  	EndHeight     types.BlockHeight
    35  	RefundAddress types.UnlockHash
    36  	// TODO: add optional keypair
    37  }