CatapultServer
v0.5.0.1 (Elephant)
|
void unapply(const model::TransactionInfo &transactionInfo)
Definition: HarvestingUtFacadeFactory.cpp:57
predicate< const validators::stateful::NotificationValidator &, const validators::ValidatorContext &, const observers::NotificationObserver &, observers::ObserverContext & > Processor
Definition: HarvestingUtFacadeFactory.cpp:95
bool ShouldEnableVerifiableReceipts
true if block chain should calculate receipts so that state changes are fully verifiable at each bloc...
Definition: BlockChainConfiguration.h:42
const std::vector< model::TransactionInfo > & transactionInfos() const
Gets all successfully applied transactions.
Definition: HarvestingUtFacadeFactory.cpp:183
Timestamp m_blockTime
Definition: HarvestingUtFacadeFactory.cpp:152
utils::ByteArray< Hash256_Size, Hash256_tag > Hash256
Definition: src/catapult/types.h:47
std::unique_ptr< model::Block > commit(const model::BlockHeader &blockHeader)
Commits all transactions into a block with specified seed header (blockHeader).
Definition: HarvestingUtFacadeFactory.cpp:203
cache::CatapultCacheDetachedDelta m_cacheDetachedDelta
Definition: HarvestingUtFacadeFactory.cpp:156
Block chain configuration settings.
Definition: BlockChainConfiguration.h:33
constexpr bool IsValidationResultSuccess(ValidationResult result)
Returns a value indicating whether the validation result is a success.
Definition: ValidationResult.h:90
Context passed to all the observers.
Definition: ObserverContext.h:78
utils::BaseValue< uint64_t, Amount_tag > Amount
Definition: src/catapult/types.h:76
std::unique_ptr< cache::CatapultCacheDelta > m_pCacheDelta
Definition: HarvestingUtFacadeFactory.cpp:157
std::function< bool(TArgs...)> predicate
A predicate function.
Definition: functions.h:31
A strongly typed notification validator.
Definition: NotificationValidator.h:30
utils::BaseValue< uint64_t, Height_tag > Height
Definition: src/catapult/types.h:85
model::NetworkInfo Network
Network info.
Definition: ExecutionConfiguration.h:39
bool ShouldEnableVerifiableState
true if block chain should calculate state hashes so that state is fully verifiable at each block.
Definition: BlockChainConfiguration.h:39
void enableUndo()
Enables subsequent notifications to be undone.
Definition: ProcessingNotificationSubscriber.cpp:44
A notification subscriber that processes notifications.
Definition: ProcessingNotificationSubscriber.h:29
chain::ExecutionConfiguration m_executionConfig
Definition: HarvestingUtFacadeFactory.cpp:154
std::vector< std::shared_ptr< const Transaction > > Transactions
Container of transactions.
Definition: BlockUtils.h:71
std::unique_ptr< Block > StitchBlock(const BlockHeader &blockHeader, const Transactions &transactions)
Creates a new block by stitching together blockHeader and transactions.
Definition: BlockUtils.cpp:146
model::BlockStatementBuilder m_blockStatementBuilder
Definition: HarvestingUtFacadeFactory.cpp:158
A transaction and its associated metadata.
Definition: EntityInfo.h:104
ObserverPointer pObserver
Observer.
Definition: ExecutionConfiguration.h:42
Definition: HarvestingUtFacadeFactory.cpp:32
std::unique_ptr< model::Block > commit(const model::BlockHeader &blockHeader, const model::Transactions &transactions)
Definition: HarvestingUtFacadeFactory.cpp:62
const cache::CatapultCache & m_cache
Definition: HarvestingUtFacadeFactory.h:84
Height height() const
Definition: HarvestingUtFacadeFactory.cpp:48
size_t size() const
Gets the number of successfully applied transactions.
Definition: HarvestingUtFacadeFactory.cpp:179
Contextual information passed to stateful validators.
Definition: ValidatorContext.h:32
bool apply(const model::TransactionInfo &transactionInfo)
Definition: HarvestingUtFacadeFactory.cpp:53
model::BlockChainConfiguration m_blockChainConfig
Definition: HarvestingUtFacadeFactory.h:85
#define CATAPULT_THROW_OUT_OF_RANGE(MESSAGE)
Macro used to throw a catapult out of range.
Definition: exceptions.h:191
Hash256 CalculateMerkleHash(const BlockStatement &statement)
Calculates the merkle hash for statement.
Definition: BlockStatement.cpp:83
Wrapper around a strongly typed entity and its associated metadata.
Definition: WeakEntityInfo.h:33
Impl(Timestamp blockTime, const cache::CatapultCache &cache, const model::BlockChainConfiguration &blockChainConfig, const chain::ExecutionConfiguration &executionConfig)
Definition: HarvestingUtFacadeFactory.cpp:34
Configuration for executing entities.
Definition: ExecutionConfiguration.h:30
Height height() const
Gets the cache height associated with this delta.
Definition: CatapultCache.cpp:175
HarvestingUtFacadeFactory(const cache::CatapultCache &cache, const model::BlockChainConfiguration &blockChainConfig, const chain::ExecutionConfiguration &executionConfig)
Creates a factory around cache, blockChainConfig and executionConfig.
Definition: HarvestingUtFacadeFactory.cpp:220
A notification subscriber that captures notifications and allows them to be undone.
Definition: ProcessingUndoNotificationSubscriber.h:28
std::vector< model::TransactionInfo > m_transactionInfos
Definition: HarvestingUtFacadeFactory.h:63
uint64_t ImportanceGrouping
Definition: BlockChainConfiguration.h:61
MosaicId CurrencyMosaicId
Mosaic id used as primary chain currency.
Definition: BlockChainConfiguration.h:45
std::unique_ptr< Impl > m_pImpl
Definition: HarvestingUtFacadeFactory.h:67
Block independent mutable state passed to all observers.
Definition: ObserverContext.h:54
std::unique_ptr< BlockStatement > build()
Builds a block statement.
Definition: BlockStatementBuilder.cpp:88
void undo()
Undoes all executions since enableUndo was first called.
Definition: ProcessingNotificationSubscriber.cpp:48
void unapply()
Unapplies last successfully applied transaction.
Definition: HarvestingUtFacadeFactory.cpp:195
Collection of receipts scoped to a block.
Definition: BlockStatementBuilder.h:27
Central cache holding all sub caches.
Definition: CatapultCache.h:40
Stateful catapult information.
Definition: CatapultState.h:27
cache::CatapultCacheDetachableDelta m_cacheDetachableDelta
Definition: HarvestingUtFacadeFactory.cpp:155
~HarvestingUtFacade()
Destroys the facade.
A strongly typed notification observer.
Definition: NotificationObserver.h:29
Factory for creating unconfirmed transactions facades.
Definition: HarvestingUtFacadeFactory.h:71
Synchronized cache composed of stateful account information.
Definition: AccountStateCache.h:72
bool process(const Processor &processor)
Definition: HarvestingUtFacadeFactory.cpp:97
void unapply(const model::WeakEntityInfo &weakEntityInfo)
Definition: HarvestingUtFacadeFactory.cpp:139
validators::ValidationResult result() const
Gets the aggregate result of processed notifications.
Definition: ProcessingNotificationSubscriber.cpp:40
#define CATAPULT_THROW_RUNTIME_ERROR(MESSAGE)
Macro used to throw a catapult runtime error.
Definition: exceptions.h:167
void popSource()
Decrements the current primary source and removes all receipts associated with it.
Definition: BlockStatementBuilder.cpp:38
ResolverContextFactoryFunc ResolverContextFactory
Resolver context factory.
Definition: ExecutionConfiguration.h:51
Detached delta of the catapult cache.
Definition: CatapultCacheDetachedDelta.h:30
PublisherPointer pNotificationPublisher
Notification publisher.
Definition: ExecutionConfiguration.h:48
std::shared_ptr< TEntity > pEntity
Entity pointer.
Definition: EntityInfo.h:45
bool apply(const model::WeakEntityInfo &weakEntityInfo)
Definition: HarvestingUtFacadeFactory.cpp:119
Definition: AddressExtractionExtension.cpp:28
Definition: CatapultCacheDetachableDelta.h:32
chain::ExecutionConfiguration m_executionConfig
Definition: HarvestingUtFacadeFactory.h:86
Amount CalculateTransactionFee(BlockFeeMultiplier feeMultiplier, const Transaction &transaction)
Calculates the fee for transaction contained in block with feeMultiplier.
Definition: FeeUtils.cpp:26
Hash256 EntityHash
Entity hash.
Definition: EntityInfo.h:48
HarvestingUtFacade(Timestamp blockTime, const cache::CatapultCache &cache, const model::BlockChainConfiguration &blockChainConfig, const chain::ExecutionConfiguration &executionConfig)
Creates a facade around blockTime, cache, blockChainConfig and executionConfig.
Definition: HarvestingUtFacadeFactory.cpp:165
ValidatorPointer pValidator
Stateful validator.
Definition: ExecutionConfiguration.h:45
ImportanceHeight ConvertToImportanceHeight(Height height, Height::ValueType grouping)
Definition: ImportanceHeight.cpp:33
const cache::CatapultCache & m_cache
Definition: JointValidator.cpp:84
std::unique_ptr< HarvestingUtFacade > create(Timestamp blockTime) const
Creates a facade for applying transactions at a given block time (blockTime).
Definition: HarvestingUtFacadeFactory.cpp:229
model::BlockChainConfiguration m_blockChainConfig
Definition: HarvestingUtFacadeFactory.cpp:153
Facade around unconfirmed transactions cache and updater.
Definition: HarvestingUtFacadeFactory.h:30
bool apply(const model::TransactionInfo &transactionInfo)
Attempts to apply transactionInfo to the cache.
Definition: HarvestingUtFacadeFactory.cpp:187
TransactionInfo copy() const
Creates a (shallow) copy of this info.
Definition: EntityInfo.h:122
void undo()
Undoes all executions.
Definition: ProcessingUndoNotificationSubscriber.cpp:32
Height height() const
Gets locked height.
Definition: HarvestingUtFacadeFactory.cpp:175