CatapultServer
v0.5.0.1 (Elephant)
|
Go to the documentation of this file.
27 class PrunableBlockStorage;
34 void MoveBlockFiles(PrunableBlockStorage& sourceStorage, BlockStorage& destinationStorage,
Height startHeight);
virtual std::pair< std::vector< uint8_t >, bool > loadBlockStatementData(Height height) const =0
Returns the optional block statement data at height.
utils::BaseValue< uint64_t, Height_tag > Height
Definition: src/catapult/types.h:85
virtual std::shared_ptr< const model::BlockElement > loadBlockElement(Height height) const =0
Returns the block element (owning a block) at height.
Interface that allows saving, loading and pruning blocks.
Definition: BlockStorage.h:63
void ReadBlockStatement(InputStream &inputStream, model::BlockStatement &blockStatement)
Reads block statement from inputStream into blockStatement.
Definition: BlockStatementSerializer.cpp:123
Immutable wrapper for basic types, to provide some type-safety.
Definition: BaseValue.h:100
virtual void dropBlocksAfter(Height height)=0
Drops all blocks after height.
void MoveBlockFiles(PrunableBlockStorage &sourceStorage, BlockStorage &destinationStorage, Height startHeight)
Moves block files starting at startHeight from sourceStorage to destinationStorage.
Definition: MoveBlockFiles.cpp:28
virtual Height chainHeight() const =0
Gets the number of blocks.
#define CATAPULT_THROW_INVALID_ARGUMENT_1(MESSAGE, PARAM1)
Macro used to throw a catapult invalid argument with a single parameter.
Definition: exceptions.h:183
Definition: AddressExtractionExtension.cpp:28
virtual void purge()=0
Purges all blocks from storage.
Interface for saving and loading blocks.
Definition: BlockStorage.h:50
virtual void saveBlock(const model::BlockElement &blockElement)=0
Saves blockElement.