|
CatapultServer
v0.5.0.1 (Elephant)
|
A manager for registering plugins. More...

Public Member Functions | |
| PluginManager (const model::BlockChainConfiguration &config, const StorageConfiguration &storageConfig, const config::InflationConfiguration &inflationConfig) | |
| Creates a new plugin manager around config, storageConfig and inflationConfig. More... | |
| const model::BlockChainConfiguration & | config () const |
| Gets the block chain configuration. More... | |
| const StorageConfiguration & | storageConfig () const |
| Gets the storage configuration. More... | |
| cache::CacheConfiguration | cacheConfig (const std::string &name) const |
| Gets the cache configuration for cache with name. More... | |
| const config::InflationConfiguration & | inflationConfig () const |
| Gets the inflation configuration. More... | |
| void | addTransactionSupport (std::unique_ptr< model::TransactionPlugin > &&pTransactionPlugin) |
| Adds support for a transaction described by pTransactionPlugin. More... | |
| const model::TransactionRegistry & | transactionRegistry () const |
| Gets the transaction registry. More... | |
| template<typename TStorageTraits , typename TCache > | |
| void | addCacheSupport (std::unique_ptr< TCache > &&pSubCache) |
| Adds support for a sub cache described by pSubCache. More... | |
| void | addCacheSupport (std::unique_ptr< cache::SubCachePlugin > &&pSubCachePlugin) |
| Adds support for a sub cache registered by pSubCachePlugin. More... | |
| cache::CatapultCache | createCache () |
| Creates a catapult cache. More... | |
| void | addHandlerHook (const HandlerHook &hook) |
| Adds a (non-diagnostic) handler hook. More... | |
| void | addHandlers (ionet::ServerPacketHandlers &handlers, const cache::CatapultCache &cache) const |
| Adds all (non-diagnostic) handlers to handlers given cache. More... | |
| void | addDiagnosticHandlerHook (const HandlerHook &hook) |
| Adds a diagnostic handler hook. More... | |
| void | addDiagnosticCounterHook (const CounterHook &hook) |
| Adds a diagnostic counter hook. More... | |
| void | addDiagnosticHandlers (ionet::ServerPacketHandlers &handlers, const cache::CatapultCache &cache) const |
| Adds all diagnostic handlers to handlers given cache. More... | |
| void | addDiagnosticCounters (std::vector< utils::DiagnosticCounter > &counters, const cache::CatapultCache &cache) const |
| Adds all diagnostic counters to counters given cache. More... | |
| void | addStatelessValidatorHook (const StatelessValidatorHook &hook) |
| Adds a stateless validator hook. More... | |
| void | addStatefulValidatorHook (const StatefulValidatorHook &hook) |
| Adds a stateful validator hook. More... | |
| StatelessValidatorPointer | createStatelessValidator (const validators::ValidationResultPredicate &isSuppressedFailure) const |
| Creates a stateless validator that ignores suppressed failures according to isSuppressedFailure. More... | |
| StatelessValidatorPointer | createStatelessValidator () const |
| Creates a stateless validator with no suppressed failures. More... | |
| StatefulValidatorPointer | createStatefulValidator (const validators::ValidationResultPredicate &isSuppressedFailure) const |
| Creates a stateful validator that ignores suppressed failures according to isSuppressedFailure. More... | |
| StatefulValidatorPointer | createStatefulValidator () const |
| Creates a stateful validator with no suppressed failures. More... | |
| void | addObserverHook (const ObserverHook &hook) |
| Adds an observer hook. More... | |
| void | addTransientObserverHook (const ObserverHook &hook) |
| Adds a (transient) observer hook. More... | |
| ObserverPointer | createObserver () const |
| Creates an observer. More... | |
| ObserverPointer | createPermanentObserver () const |
| Creates an observer that only observes permanent state changes. More... | |
| void | addMosaicResolver (const MosaicResolver &resolver) |
| Adds a mosaic resolver. More... | |
| void | addAddressResolver (const AddressResolver &resolver) |
| Adds an address resolver. More... | |
| model::ResolverContext | createResolverContext (const cache::ReadOnlyCatapultCache &cache) const |
| Creates a resolver context given cache. More... | |
| PublisherPointer | createNotificationPublisher (model::PublicationMode mode=model::PublicationMode::All) const |
| Creates a notification publisher for the specified mode. More... | |
Private Attributes | |
| model::BlockChainConfiguration | m_config |
| StorageConfiguration | m_storageConfig |
| config::InflationConfiguration | m_inflationConfig |
| model::TransactionRegistry | m_transactionRegistry |
| cache::CatapultCacheBuilder | m_cacheBuilder |
| std::vector< HandlerHook > | m_nonDiagnosticHandlerHooks |
| std::vector< HandlerHook > | m_diagnosticHandlerHooks |
| std::vector< CounterHook > | m_diagnosticCounterHooks |
| std::vector< StatelessValidatorHook > | m_statelessValidatorHooks |
| std::vector< StatefulValidatorHook > | m_statefulValidatorHooks |
| std::vector< ObserverHook > | m_observerHooks |
| std::vector< ObserverHook > | m_transientObserverHooks |
| std::vector< MosaicResolver > | m_mosaicResolvers |
| std::vector< AddressResolver > | m_addressResolvers |
A manager for registering plugins.
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
| catapult::plugins::PluginManager::PluginManager | ( | const model::BlockChainConfiguration & | config, |
| const StorageConfiguration & | storageConfig, | ||
| const config::InflationConfiguration & | inflationConfig | ||
| ) |
Creates a new plugin manager around config, storageConfig and inflationConfig.
| void catapult::plugins::PluginManager::addAddressResolver | ( | const AddressResolver & | resolver | ) |
Adds an address resolver.
| void catapult::plugins::PluginManager::addCacheSupport | ( | std::unique_ptr< cache::SubCachePlugin > && | pSubCachePlugin | ) |
Adds support for a sub cache registered by pSubCachePlugin.

|
inline |
Adds support for a sub cache described by pSubCache.


| void catapult::plugins::PluginManager::addDiagnosticCounterHook | ( | const CounterHook & | hook | ) |
Adds a diagnostic counter hook.

| void catapult::plugins::PluginManager::addDiagnosticCounters | ( | std::vector< utils::DiagnosticCounter > & | counters, |
| const cache::CatapultCache & | cache | ||
| ) | const |
Adds all diagnostic counters to counters given cache.
| void catapult::plugins::PluginManager::addDiagnosticHandlerHook | ( | const HandlerHook & | hook | ) |
Adds a diagnostic handler hook.

| void catapult::plugins::PluginManager::addDiagnosticHandlers | ( | ionet::ServerPacketHandlers & | handlers, |
| const cache::CatapultCache & | cache | ||
| ) | const |
Adds all diagnostic handlers to handlers given cache.
| void catapult::plugins::PluginManager::addHandlerHook | ( | const HandlerHook & | hook | ) |
Adds a (non-diagnostic) handler hook.

| void catapult::plugins::PluginManager::addHandlers | ( | ionet::ServerPacketHandlers & | handlers, |
| const cache::CatapultCache & | cache | ||
| ) | const |
Adds all (non-diagnostic) handlers to handlers given cache.
| void catapult::plugins::PluginManager::addMosaicResolver | ( | const MosaicResolver & | resolver | ) |
Adds a mosaic resolver.
| void catapult::plugins::PluginManager::addObserverHook | ( | const ObserverHook & | hook | ) |
Adds an observer hook.

| void catapult::plugins::PluginManager::addStatefulValidatorHook | ( | const StatefulValidatorHook & | hook | ) |
Adds a stateful validator hook.

| void catapult::plugins::PluginManager::addStatelessValidatorHook | ( | const StatelessValidatorHook & | hook | ) |
Adds a stateless validator hook.

| void catapult::plugins::PluginManager::addTransactionSupport | ( | std::unique_ptr< model::TransactionPlugin > && | pTransactionPlugin | ) |
Adds support for a transaction described by pTransactionPlugin.


| void catapult::plugins::PluginManager::addTransientObserverHook | ( | const ObserverHook & | hook | ) |
Adds a (transient) observer hook.

| cache::CacheConfiguration catapult::plugins::PluginManager::cacheConfig | ( | const std::string & | name | ) | const |
Gets the cache configuration for cache with name.

| const model::BlockChainConfiguration & catapult::plugins::PluginManager::config | ( | ) | const |
Gets the block chain configuration.

| cache::CatapultCache catapult::plugins::PluginManager::createCache | ( | ) |
Creates a catapult cache.

| PluginManager::PublisherPointer catapult::plugins::PluginManager::createNotificationPublisher | ( | model::PublicationMode | mode = model::PublicationMode::All | ) | const |
Creates a notification publisher for the specified mode.


| PluginManager::ObserverPointer catapult::plugins::PluginManager::createObserver | ( | ) | const |
Creates an observer.


| PluginManager::ObserverPointer catapult::plugins::PluginManager::createPermanentObserver | ( | ) | const |
Creates an observer that only observes permanent state changes.
| model::ResolverContext catapult::plugins::PluginManager::createResolverContext | ( | const cache::ReadOnlyCatapultCache & | cache | ) | const |
Creates a resolver context given cache.

| PluginManager::StatefulValidatorPointer catapult::plugins::PluginManager::createStatefulValidator | ( | ) | const |
Creates a stateful validator with no suppressed failures.
| PluginManager::StatefulValidatorPointer catapult::plugins::PluginManager::createStatefulValidator | ( | const validators::ValidationResultPredicate & | isSuppressedFailure | ) | const |
Creates a stateful validator that ignores suppressed failures according to isSuppressedFailure.

| PluginManager::StatelessValidatorPointer catapult::plugins::PluginManager::createStatelessValidator | ( | ) | const |
Creates a stateless validator with no suppressed failures.
| PluginManager::StatelessValidatorPointer catapult::plugins::PluginManager::createStatelessValidator | ( | const validators::ValidationResultPredicate & | isSuppressedFailure | ) | const |
Creates a stateless validator that ignores suppressed failures according to isSuppressedFailure.

| const config::InflationConfiguration & catapult::plugins::PluginManager::inflationConfig | ( | ) | const |
Gets the inflation configuration.

| const StorageConfiguration & catapult::plugins::PluginManager::storageConfig | ( | ) | const |
Gets the storage configuration.
| const model::TransactionRegistry & catapult::plugins::PluginManager::transactionRegistry | ( | ) | const |
Gets the transaction registry.

|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |