hornet

package
v0.4.0-rc3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 24, 2020 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	HORNET_TX_METADATA_SOLID     = 0
	HORNET_TX_METADATA_CONFIRMED = 1
)

Variables

This section is empty.

Functions

func RequestedTransactionCaller

func RequestedTransactionCaller(handler interface{}, params ...interface{})

func TransactionCaller

func TransactionCaller(handler interface{}, params ...interface{})

Types

type Address

type Address struct {
	objectstorage.StorableObjectFlags
	Address []byte
	TxHash  []byte
}

func (*Address) GetAddress

func (a *Address) GetAddress() trinary.Hash

func (*Address) GetStorageKey

func (a *Address) GetStorageKey() []byte

func (*Address) GetTransactionHash

func (a *Address) GetTransactionHash() trinary.Hash

func (*Address) MarshalBinary

func (a *Address) MarshalBinary() (data []byte, err error)

func (*Address) UnmarshalBinary

func (a *Address) UnmarshalBinary(data []byte) error

func (*Address) Update

func (a *Address) Update(other objectstorage.StorableObject)

type Approver

type Approver struct {
	objectstorage.StorableObjectFlags
	TxHash       []byte
	ApproverHash []byte
}

func (*Approver) GetApproverHash

func (a *Approver) GetApproverHash() trinary.Hash

func (*Approver) GetStorageKey

func (a *Approver) GetStorageKey() []byte

func (*Approver) GetTransactionHash

func (a *Approver) GetTransactionHash() trinary.Hash

func (*Approver) MarshalBinary

func (a *Approver) MarshalBinary() (data []byte, err error)

func (*Approver) UnmarshalBinary

func (a *Approver) UnmarshalBinary(data []byte) error

func (*Approver) Update

func (a *Approver) Update(other objectstorage.StorableObject)

type FirstSeenTx

type FirstSeenTx struct {
	objectstorage.StorableObjectFlags
	FirstSeenLatestMilestoneIndex milestone_index.MilestoneIndex
	TxHash                        []byte
}

func (*FirstSeenTx) GetFirstSeenLatestMilestoneIndex

func (t *FirstSeenTx) GetFirstSeenLatestMilestoneIndex() milestone_index.MilestoneIndex

func (*FirstSeenTx) GetStorageKey

func (t *FirstSeenTx) GetStorageKey() []byte

func (*FirstSeenTx) GetTransactionHash

func (t *FirstSeenTx) GetTransactionHash() trinary.Hash

func (*FirstSeenTx) MarshalBinary

func (t *FirstSeenTx) MarshalBinary() (data []byte, err error)

func (*FirstSeenTx) UnmarshalBinary

func (t *FirstSeenTx) UnmarshalBinary(data []byte) error

func (*FirstSeenTx) Update

func (t *FirstSeenTx) Update(other objectstorage.StorableObject)

type SolidEntryPoints

type SolidEntryPoints struct {
	// contains filtered or unexported fields
}

func NewSolidEntryPoints

func NewSolidEntryPoints() *SolidEntryPoints

func SolidEntryPointsFromBytes

func SolidEntryPointsFromBytes(solidEntryPointsBytes []byte) (*SolidEntryPoints, error)

func (*SolidEntryPoints) Add

func (s *SolidEntryPoints) Add(transactionHash trinary.Hash, milestoneIndex milestone_index.MilestoneIndex)

func (*SolidEntryPoints) Clear

func (s *SolidEntryPoints) Clear()

func (*SolidEntryPoints) Contains

func (s *SolidEntryPoints) Contains(transactionHash trinary.Hash) bool

func (*SolidEntryPoints) GetBytes

func (s *SolidEntryPoints) GetBytes() []byte

func (*SolidEntryPoints) Hashes

func (s *SolidEntryPoints) Hashes() []trinary.Hash

func (*SolidEntryPoints) IsModified

func (s *SolidEntryPoints) IsModified() bool

func (*SolidEntryPoints) SetModified

func (s *SolidEntryPoints) SetModified(modified bool)

type SpentAddress

type SpentAddress struct {
	objectstorage.StorableObjectFlags

	Address []byte
}

func (*SpentAddress) GetAddress

func (sa *SpentAddress) GetAddress() trinary.Hash

func (*SpentAddress) GetStorageKey

func (sa *SpentAddress) GetStorageKey() []byte

func (*SpentAddress) MarshalBinary

func (sa *SpentAddress) MarshalBinary() (data []byte, err error)

func (*SpentAddress) UnmarshalBinary

func (sa *SpentAddress) UnmarshalBinary(data []byte) error

func (*SpentAddress) Update

func (sa *SpentAddress) Update(other objectstorage.StorableObject)

type Tag

type Tag struct {
	objectstorage.StorableObjectFlags
	Tag    []byte
	TxHash []byte
}

func (*Tag) GetStorageKey

func (t *Tag) GetStorageKey() []byte

func (*Tag) GetTag

func (t *Tag) GetTag() trinary.Hash

func (*Tag) GetTransactionHash

func (t *Tag) GetTransactionHash() trinary.Hash

func (*Tag) MarshalBinary

func (t *Tag) MarshalBinary() (data []byte, err error)

func (*Tag) UnmarshalBinary

func (t *Tag) UnmarshalBinary(data []byte) error

func (*Tag) Update

func (t *Tag) Update(other objectstorage.StorableObject)

type Transaction

type Transaction struct {
	objectstorage.StorableObjectFlags

	TxHash []byte

	// Decompressed iota.go Transaction containing Hash
	Tx *transaction.Transaction

	// Compressed bytes as received via gossip
	RawBytes []byte
	// contains filtered or unexported fields
}

func NewTransaction

func NewTransaction(transaction *transaction.Transaction, transactionBytes []byte) *Transaction

func (*Transaction) GetBranch

func (tx *Transaction) GetBranch() trinary.Hash

func (*Transaction) GetHash

func (tx *Transaction) GetHash() trinary.Hash

func (*Transaction) GetStorageKey

func (tx *Transaction) GetStorageKey() []byte

func (*Transaction) GetTimestamp

func (tx *Transaction) GetTimestamp() int64

func (*Transaction) GetTrunk

func (tx *Transaction) GetTrunk() trinary.Hash

func (*Transaction) IsHead

func (tx *Transaction) IsHead() bool

func (*Transaction) IsTail

func (tx *Transaction) IsTail() bool

func (*Transaction) MarshalBinary

func (tx *Transaction) MarshalBinary() (data []byte, err error)

func (*Transaction) UnmarshalBinary

func (tx *Transaction) UnmarshalBinary(data []byte) error

func (*Transaction) Update

func (tx *Transaction) Update(other objectstorage.StorableObject)

type TransactionMetadata

type TransactionMetadata struct {
	objectstorage.StorableObjectFlags
	syncutils.RWMutex

	TxHash []byte
	// contains filtered or unexported fields
}

func (*TransactionMetadata) GetConfirmed

func (*TransactionMetadata) GetMetadata

func (m *TransactionMetadata) GetMetadata() byte

func (*TransactionMetadata) GetSolidificationTimestamp

func (m *TransactionMetadata) GetSolidificationTimestamp() int32

func (*TransactionMetadata) GetStorageKey

func (m *TransactionMetadata) GetStorageKey() []byte

func (*TransactionMetadata) IsSolid

func (m *TransactionMetadata) IsSolid() bool

func (*TransactionMetadata) MarshalBinary

func (m *TransactionMetadata) MarshalBinary() (data []byte, err error)

func (*TransactionMetadata) Reset

func (m *TransactionMetadata) Reset()

func (*TransactionMetadata) SetConfirmed

func (m *TransactionMetadata) SetConfirmed(confirmed bool, confirmationIndex milestone_index.MilestoneIndex)

func (*TransactionMetadata) SetSolid

func (m *TransactionMetadata) SetSolid(solid bool)

func (*TransactionMetadata) UnmarshalBinary

func (m *TransactionMetadata) UnmarshalBinary(data []byte) error

func (*TransactionMetadata) Update

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL