use Org\Mxchange\CoreFramework\Loader\ClassLoader;
use Org\Mxchange\CoreFramework\Manager\ManageableApplication;
use Org\Mxchange\CoreFramework\Object\BaseFrameworkSystem;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Registry\Registerable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
use Org\Mxchange\CoreFramework\Template\CompileableTemplate;
/**
use Org\Mxchange\CoreFramework\Command\Commandable;
use Org\Mxchange\CoreFramework\Controller\Controller;
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Resolver\Command\CommandResolver;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get a registry and the application instance from it
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
/*
* ----------------------- Bootstrapping phase ------------------------
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('BOOTSTRAP: Bootstrap finished.');
// Get apt-proxy instance
- $proxyInstance = Registry::getRegistry()->getInstance('apt_proxy');
+ $proxyInstance = GenericRegistry::getRegistry()->getInstance('apt_proxy');
// Add some apt-proxy-specific filters
$proxyInstance->addExtraAptProxyFilters();
// Get task handler instance
- $handlerInstance = Registry::getRegistry()->getInstance('task_handler');
+ $handlerInstance = GenericRegistry::getRegistry()->getInstance('task_handler');
// Debug message
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('MAIN: --- Entering main loop. ---');
use Org\Mxchange\CoreFramework\Command\Commandable;
use Org\Mxchange\CoreFramework\Controller\Controller;
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Resolver\Command\CommandResolver;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get a registry and the application instance from it
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
/*
* ----------------------- Bootstrapping phase ------------------------
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('BOOTSTRAP: Bootstrap finished.');
// Get chat instance
- $chatInstance = Registry::getRegistry()->getInstance('chat');
+ $chatInstance = GenericRegistry::getRegistry()->getInstance('chat');
// Add some chat-specific filters
$chatInstance->addExtraChatFilters();
// Get task handler instance
- $handlerInstance = Registry::getRegistry()->getInstance('task_handler');
+ $handlerInstance = GenericRegistry::getRegistry()->getInstance('task_handler');
// Debug message
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('MAIN: --- Entering main loop. ---');
use Org\Mxchange\CoreFramework\Command\Commandable;
use Org\Mxchange\CoreFramework\Controller\Controller;
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Resolver\Command\CommandResolver;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get a registry and the application instance from it
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
/*
* ----------------------- Bootstrapping phase ------------------------
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('BOOTSTRAP: Bootstrap finished.');
// Get crawler instance
- $crawlerInstance = Registry::getRegistry()->getInstance('crawler');
+ $crawlerInstance = GenericRegistry::getRegistry()->getInstance('crawler');
// Add some crawler-specific filters
$crawlerInstance->addExtraCrawlerFilters();
// Get task handler instance
- $handlerInstance = Registry::getRegistry()->getInstance('task_handler');
+ $handlerInstance = GenericRegistry::getRegistry()->getInstance('task_handler');
// Debug message
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('MAIN: --- Entering main loop. ---');
use Org\Mxchange\CoreFramework\Command\Commandable;
use Org\Mxchange\CoreFramework\Controller\Controller;
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Resolver\Command\CommandResolver;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get a registry and the application instance from it
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
/*
* ----------------------- Bootstrapping phase ------------------------
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('BOOTSTRAP: Bootstrap finished.');
// Get cruncher instance
- $cruncherInstance = Registry::getRegistry()->getInstance('cruncher');
+ $cruncherInstance = GenericRegistry::getRegistry()->getInstance('cruncher');
// Add some cruncher-specific filters
$cruncherInstance->addExtraCruncherFilters();
// Get task handler instance
- $handlerInstance = Registry::getRegistry()->getInstance('task_handler');
+ $handlerInstance = GenericRegistry::getRegistry()->getInstance('task_handler');
// Debug message
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('MAIN: --- Entering main loop. ---');
use Org\Mxchange\CoreFramework\Command\Commandable;
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Controller\Controller;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Resolver\Command\CommandResolver;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get a registry and the application instance from it
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
/*
* ----------------------- Bootstrapping phase ------------------------
$nodeInstance->activateNode($requestInstance, $responseInstance);
// Get task handler instance
- $handlerInstance = Registry::getRegistry()->getInstance('task_handler');
+ $handlerInstance = GenericRegistry::getRegistry()->getInstance('task_handler');
// Debug message
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('MAIN: --- Entering main loop. ---');
use Org\Mxchange\CoreFramework\Command\Commandable;
use Org\Mxchange\CoreFramework\Controller\Controller;
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Resolver\Command\CommandResolver;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get a registry and the application instance from it
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
/*
* ----------------------- Bootstrapping phase ------------------------
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('BOOTSTRAP: Bootstrap finished.');
// Get miner instance
- $minerInstance = Registry::getRegistry()->getInstance('miner');
+ $minerInstance = GenericRegistry::getRegistry()->getInstance('miner');
// Add some miner-specific filters
$minerInstance->addExtraMinerFilters();
// Get task handler instance
- $handlerInstance = Registry::getRegistry()->getInstance('task_handler');
+ $handlerInstance = GenericRegistry::getRegistry()->getInstance('task_handler');
// Debug message
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('MAIN: --- Entering main loop. ---');
use Org\Shipsimu\Hub\Generic\BaseHubSystem;
// Import framework stuff
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\State\Stateable;
/**
parent::__construct($className);
// Set this crawler instance in registry
- Registry::getRegistry()->addInstance('crawler', $this);
+ GenericRegistry::getRegistry()->addInstance('crawler', $this);
// Init state which sets the state to 'init'
$this->initState();
// Import framework stuff
use Org\Mxchange\CoreFramework\Database\Updateable;
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A general hub cruncher class
parent::__construct($className);
// Set this cruncher instance in registry
- Registry::getRegistry()->addInstance('cruncher', $this);
+ GenericRegistry::getRegistry()->addInstance('cruncher', $this);
// Init this cruncher
$this->initCruncher();
// Import framework stuff
use Org\Mxchange\CoreFramework\Generic\NullPointerException;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Registry\Registerable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
use Org\Mxchange\CoreFramework\Socket\InvalidSocketException;
// Import SPL stuff
// Try to resolve the socket resource
try {
// Get the helper instance from registry
- $helperInstance = Registry::getRegistry()->getInstance('connection');
+ $helperInstance = GenericRegistry::getRegistry()->getInstance('connection');
// Possibly noisy debug message
/* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('PACKAGE-SOCKET-DISCOVERY: Going to resolve socket from peer state and given package data ...');
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for network packages
*/
public static final function createChainByTagsArray (array $tags) {
// Get a registry key from tags array, this does mostly call implode()
- $registryKey = Registry::getRegistryKeyFromArray('package_filter_chain', $tags);
+ $registryKey = GenericRegistry::getRegistryKeyFromArray('package_filter_chain', $tags);
// Is the registry key there?
- if (Registry::getRegistry()->instanceExists($registryKey)) {
+ if (GenericRegistry::getRegistry()->instanceExists($registryKey)) {
// Yes, then use that instance
- $chainInstance = Registry::getRegistry()->getInstance($registryKey);
+ $chainInstance = GenericRegistry::getRegistry()->getInstance($registryKey);
} else {
// Initialize a filter chain class
$chainInstance = self::createObjectByConfiguredName('package_filter_chain_class');
} // END - foreach
// Add the finished chain to the registry
- Registry::getRegistry()->addInstance($registryKey, $chainInstance);
+ GenericRegistry::getRegistry()->addInstance($registryKey, $chainInstance);
}
// Return the chain instance
return $chainInstance;
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for chunk handler
*/
public static final function createChunkHandlerInstance () {
// If there is no handler?
- if (Registry::getRegistry()->instanceExists('chunk_handler')) {
+ if (GenericRegistry::getRegistry()->instanceExists('chunk_handler')) {
// Get handler from registry
- $handlerInstance = Registry::getRegistry()->getInstance('chunk_handler');
+ $handlerInstance = GenericRegistry::getRegistry()->getInstance('chunk_handler');
} else {
// Get the handler instance
$handlerInstance = self::createObjectByConfiguredName('chunk_handler_class');
// Add it to the registry
- Registry::getRegistry()->addInstance('chunk_handler', $handlerInstance);
+ GenericRegistry::getRegistry()->addInstance('chunk_handler', $handlerInstance);
}
// Return the instance
return $handlerInstance;
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for !!!
*/
public static final function create???Instance () {
// If there is no handler?
- if (Registry::getRegistry()->instanceExists('|||')) {
+ if (GenericRegistry::getRegistry()->instanceExists('|||')) {
// Get handler from registry
- $%%%Instance = Registry::getRegistry()->getInstance('|||');
+ $%%%Instance = GenericRegistry::getRegistry()->getInstance('|||');
} else {
// Get the handler instance
$%%%Instance = self::createObjectByConfiguredName('|||_class');
// Add it to the registry
- Registry::getRegistry()->addInstance('|||', $%%%Instance);
+ GenericRegistry::getRegistry()->addInstance('|||', $%%%Instance);
}
// Return the instance
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* An object factory for clients
$registryKey = strtolower($protocolInstance->getProtocolName()) . '_client';
// Is the key already in registry?
- if (Registry::getRegistry()->instanceExists($registryKey)) {
+ if (GenericRegistry::getRegistry()->instanceExists($registryKey)) {
// Then use that instance
- $clientInstance = Registry::getRegistry()->getInstance($registryKey);
+ $clientInstance = GenericRegistry::getRegistry()->getInstance($registryKey);
// Is socket instance given?
if ($socketInstance instanceof StorableSocket) {
$clientInstance = self::createObjectByConfiguredName($registryKey, array($socketInstance));
// Set it in registry for later re-use
- Registry::getRegistry()->addInstance($registryKey, $clientInstance);
+ GenericRegistry::getRegistry()->addInstance($registryKey, $clientInstance);
}
// Return the prepared instance
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for communicator
*/
public static final function createCommunicatorInstance ($configEntry, $communicatorType) {
// If there is no communicator?
- if (Registry::getRegistry()->instanceExists($communicatorType . '_communicator')) {
+ if (GenericRegistry::getRegistry()->instanceExists($communicatorType . '_communicator')) {
// Get communicator from registry
- $communicatorInstance = Registry::getRegistry()->getInstance($communicatorType . '_communicator');
+ $communicatorInstance = GenericRegistry::getRegistry()->getInstance($communicatorType . '_communicator');
} else {
// Get the communicator instance
$communicatorInstance = self::createObjectByConfiguredName($configEntry);
// Add it to the registry
- Registry::getRegistry()->addInstance($communicatorType . '_communicator', $communicatorInstance);
+ GenericRegistry::getRegistry()->addInstance($communicatorType . '_communicator', $communicatorInstance);
}
// Return the instance
return $communicatorInstance;
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for Decodeable objects
*/
public static final function createPackageDecoderInstance () {
// If there is no handler?
- if (Registry::getRegistry()->instanceExists('package_decoder')) {
+ if (GenericRegistry::getRegistry()->instanceExists('package_decoder')) {
// Get handler from registry
- $decoderInstance = Registry::getRegistry()->getInstance('package_decoder');
+ $decoderInstance = GenericRegistry::getRegistry()->getInstance('package_decoder');
} else {
// Get a chunk handler instance
$handlerInstance = ChunkHandlerFactory::createChunkHandlerInstance();
$decoderInstance = self::createObjectByConfiguredName('package_decoder_class', array($handlerInstance));
// Add it to the registry
- Registry::getRegistry()->addInstance('package_decoder', $decoderInstance);
+ GenericRegistry::getRegistry()->addInstance('package_decoder', $decoderInstance);
}
// Return the instance
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for DHT objects
$name = $prefix . '_dht';
// If there is no handler?
- if (Registry::getRegistry()->instanceExists($name)) {
+ if (GenericRegistry::getRegistry()->instanceExists($name)) {
// Get handler from registry
- $dhtInstance = Registry::getRegistry()->getInstance($name);
+ $dhtInstance = GenericRegistry::getRegistry()->getInstance($name);
} else {
// Get the handler instance
$dhtInstance = self::createObjectByConfiguredName($name . '_class');
// Add it to the registry
- Registry::getRegistry()->addInstance($name, $dhtInstance);
+ GenericRegistry::getRegistry()->addInstance($name, $dhtInstance);
}
// Return the instance
return $dhtInstance;
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for package discovery
*/
public static final function createPackageDiscoveryInstance () {
// Do we have an instance in the registry?
- if (Registry::getRegistry()->instanceExists('package_discovery')) {
+ if (GenericRegistry::getRegistry()->instanceExists('package_discovery')) {
// Then use this instance
- $discoveryInstance = Registry::getRegistry()->getInstance('package_discovery');
+ $discoveryInstance = GenericRegistry::getRegistry()->getInstance('package_discovery');
} else {
// Create a new instance
$discoveryInstance = self::createObjectByConfiguredName('package_recipient_discovery_class');
// Set the instance in registry for further use
- Registry::getRegistry()->addInstance('package_discovery', $discoveryInstance);
+ GenericRegistry::getRegistry()->addInstance('package_discovery', $discoveryInstance);
}
// Return the instance
return $discoveryInstance;
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for socket discovery
*/
public static final function createSocketDiscoveryInstance () {
// Do we have an instance in the registry?
- if (Registry::getRegistry()->instanceExists('socket_discovery')) {
+ if (GenericRegistry::getRegistry()->instanceExists('socket_discovery')) {
// Then use this instance
- $discoveryInstance = Registry::getRegistry()->getInstance('socket_discovery');
+ $discoveryInstance = GenericRegistry::getRegistry()->getInstance('socket_discovery');
} else {
// Create a new instance
$discoveryInstance = self::createObjectByConfiguredName('socket_discovery_class');
// Set the instance in registry for further use
- Registry::getRegistry()->addInstance('socket_discovery', $discoveryInstance);
+ GenericRegistry::getRegistry()->addInstance('socket_discovery', $discoveryInstance);
}
// Return the instance
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for message type handlers
*/
public static final function createMessageTypeHandlerInstance ($messageType) {
// Do we have an instance in the registry?
- if (Registry::getRegistry()->instanceExists('message_type_' . $messageType . '_handler')) {
+ if (GenericRegistry::getRegistry()->instanceExists('message_type_' . $messageType . '_handler')) {
// Then use this instance
- $handlerInstance = Registry::getRegistry()->getInstance('message_type_' . $messageType . '_handler');
+ $handlerInstance = GenericRegistry::getRegistry()->getInstance('message_type_' . $messageType . '_handler');
} else {
// Now prepare the tags instance
$handlerInstance = self::createObjectByConfiguredName('message_type_' . $messageType . '_handler_class');
// Set the instance in registry for further use
- Registry::getRegistry()->addInstance('message_type_' . $messageType . '_handler', $handlerInstance);
+ GenericRegistry::getRegistry()->addInstance('message_type_' . $messageType . '_handler', $handlerInstance);
}
// Return the instance
return $handlerInstance;
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for protocol handlers
*/
private static function createProtocolHandlerByType ($protocolType) {
// Do we have an instance in the registry?
- if (Registry::getRegistry()->instanceExists($protocolType . '_protocol_handler')) {
+ if (GenericRegistry::getRegistry()->instanceExists($protocolType . '_protocol_handler')) {
// Then use this instance
- $handlerInstance = Registry::getRegistry()->getInstance($protocolType . '_protocol_handler');
+ $handlerInstance = GenericRegistry::getRegistry()->getInstance($protocolType . '_protocol_handler');
} else {
// Now prepare the tags instance
$handlerInstance = self::createObjectByConfiguredName($protocolType . '_protocol_handler_class');
// Set the instance in registry for further use
- Registry::getRegistry()->addInstance($protocolType . '_protocol_handler', $handlerInstance);
+ GenericRegistry::getRegistry()->addInstance($protocolType . '_protocol_handler', $handlerInstance);
}
// Return the instance
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for ShareableInfo
$key = sprintf('connection_info_%s_%s', $protocolName, $type);
// If there is no info?
- if (Registry::getRegistry()->instanceExists($key)) {
+ if (GenericRegistry::getRegistry()->instanceExists($key)) {
// Get info from registry
- $infoInstance = Registry::getRegistry()->getInstance($key);
+ $infoInstance = GenericRegistry::getRegistry()->getInstance($key);
} else {
// Get the info instance
$infoInstance = self::createObjectByConfiguredName('connection_info_class', array($type));
// Add it to the registry
- Registry::getRegistry()->addInstance($key, $infoInstance);
+ GenericRegistry::getRegistry()->addInstance($key, $infoInstance);
}
// Trace message
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for recipient lists
*/
public static final function createRecipientListInstance () {
// Do we have an instance in the registry?
- if (Registry::getRegistry()->instanceExists('recipient_list')) {
+ if (GenericRegistry::getRegistry()->instanceExists('recipient_list')) {
// Then use this instance
- $listInstance = Registry::getRegistry()->getInstance('recipient_list');
+ $listInstance = GenericRegistry::getRegistry()->getInstance('recipient_list');
} else {
// Create a new instance
$listInstance = self::createObjectByConfiguredName('recipient_list_class');
// Set the instance in registry for further use
- Registry::getRegistry()->addInstance('recipient_list', $listInstance);
+ GenericRegistry::getRegistry()->addInstance('recipient_list', $listInstance);
}
// Return the instance
return $listInstance;
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for LocateableNode
/* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput(sprintf('UNL-FACTORY: unl=%s - CALLED!', $unl));
// If there is no handler?
- if (Registry::getRegistry()->instanceExists('unl_' . $unl)) {
+ if (GenericRegistry::getRegistry()->instanceExists('unl_' . $unl)) {
// Get handler from registry
- $unlInstance = Registry::getRegistry()->getInstance('unl_' . $unl);
+ $unlInstance = GenericRegistry::getRegistry()->getInstance('unl_' . $unl);
} else {
// Get the handler instance
$unlInstance = self::createObjectByConfiguredName('universal_node_locator_class');
$unlInstance->parseStringAsUnl($unl);
// Add it to the registry
- Registry::getRegistry()->addInstance('unl_' . $unl, $unlInstance);
+ GenericRegistry::getRegistry()->addInstance('unl_' . $unl, $unlInstance);
}
// Trace message
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
$factoryInstance = new NodeObjectFactory();
// If there is no handler?
- if (Registry::getRegistry()->instanceExists('node')) {
+ if (GenericRegistry::getRegistry()->instanceExists('node')) {
// Get handler from registry
- $nodeInstance = Registry::getRegistry()->getInstance('node');
+ $nodeInstance = GenericRegistry::getRegistry()->getInstance('node');
} elseif (($requestInstance instanceof Requestable) && ($responseInstance instanceof Responseable)) {
// The default node-mode is from our configuration
$nodeMode = $factoryInstance->getConfigInstance()->getConfigEntry('node_default_mode');
$nodeInstance = ObjectFactory::createObjectByName($className);
// Get a registry
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
// Set the app instance
$nodeInstance->setApplicationInstance($applicationInstance);
$nodeInstance->addExtraFilters($applicationInstance->getControllerInstance(), $responseInstance);
// Add it to the registry
- Registry::getRegistry()->addInstance('node', $nodeInstance);
+ GenericRegistry::getRegistry()->addInstance('node', $nodeInstance);
} else {
// Throw an exception here
throw new FactoryRequiredParameterException($factoryInstance, self::EXCEPTION_FACTORY_REQUIRE_PARAMETER);
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for package assembler
*/
public static final function createAssemblerInstance (Receivable $packageInstance) {
// If there is no assembler?
- if (Registry::getRegistry()->instanceExists('package_assembler')) {
+ if (GenericRegistry::getRegistry()->instanceExists('package_assembler')) {
// Get assembler from registry
- $assemblerInstance = Registry::getRegistry()->getInstance('package_assembler');
+ $assemblerInstance = GenericRegistry::getRegistry()->getInstance('package_assembler');
} else {
// Get the assembler instance
$assemblerInstance = self::createObjectByConfiguredName('package_assembler_class', array($packageInstance));
// Add it to the registry
- Registry::getRegistry()->addInstance('package_assembler', $assemblerInstance);
+ GenericRegistry::getRegistry()->addInstance('package_assembler', $assemblerInstance);
}
// Return the instance
return $assemblerInstance;
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for network packages
*/
public static final function createNetworkPackageInstance () {
// Do we have an instance in the registry?
- if (Registry::getRegistry()->instanceExists('network_package')) {
+ if (GenericRegistry::getRegistry()->instanceExists('network_package')) {
// Then use this instance
- $packageInstance = Registry::getRegistry()->getInstance('network_package');
+ $packageInstance = GenericRegistry::getRegistry()->getInstance('network_package');
} else {
/*
* Prepare the compressor for our package, ZLIB should be fine but we
$packageInstance = self::createObjectByConfiguredName('network_package_class', array($compressorInstance));
// Set the instance in registry for further use
- Registry::getRegistry()->addInstance('network_package', $packageInstance);
+ GenericRegistry::getRegistry()->addInstance('network_package', $packageInstance);
}
// Return the instance
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for fragmenter
*/
public static final function createFragmenterInstance ($fragmenterType) {
// If there is no fragmenter?
- if (Registry::getRegistry()->instanceExists($fragmenterType . '_fragmenter')) {
+ if (GenericRegistry::getRegistry()->instanceExists($fragmenterType . '_fragmenter')) {
// Get fragmenter from registry
- $fragmenterInstance = Registry::getRegistry()->getInstance($fragmenterType . '_fragmenter');
+ $fragmenterInstance = GenericRegistry::getRegistry()->getInstance($fragmenterType . '_fragmenter');
} else {
// Get the fragmenter instance
$fragmenterInstance = self::createObjectByConfiguredName($fragmenterType . '_fragmenter_class');
// Add it to the registry
- Registry::getRegistry()->addInstance($fragmenterType . '_fragmenter', $fragmenterInstance);
+ GenericRegistry::getRegistry()->addInstance($fragmenterType . '_fragmenter', $fragmenterInstance);
}
// Return the instance
return $fragmenterInstance;
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for producer
*/
public static final function createProducerInstance ($configEntry, $producerType) {
// If there is no producer?
- if (Registry::getRegistry()->instanceExists($producerType . '_producer')) {
+ if (GenericRegistry::getRegistry()->instanceExists($producerType . '_producer')) {
// Get producer from registry
- $producerInstance = Registry::getRegistry()->getInstance($producerType . '_producer');
+ $producerInstance = GenericRegistry::getRegistry()->getInstance($producerType . '_producer');
} else {
// Get the producer instance
$producerInstance = self::createObjectByConfiguredName($configEntry);
// Add it to the registry
- Registry::getRegistry()->addInstance($producerType . '_producer', $producerInstance);
+ GenericRegistry::getRegistry()->addInstance($producerType . '_producer', $producerInstance);
}
// Return the instance
return $producerInstance;
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for network packages
*/
public static final function createObjectTypeRegistryInstance () {
// Do we have an instance in the registry?
- if (Registry::getRegistry()->instanceExists('object_type_registry')) {
+ if (GenericRegistry::getRegistry()->instanceExists('object_type_registry')) {
// Then use this instance
- $registryInstance = Registry::getRegistry()->getInstance('object_type_registry');
+ $registryInstance = GenericRegistry::getRegistry()->getInstance('object_type_registry');
} else {
// Now prepare the tags instance
$registryInstance = self::createObjectByConfiguredName('node_object_type_registry_class');
// Set the instance in registry for further use
- Registry::getRegistry()->addInstance('object_type_registry', $registryInstance);
+ GenericRegistry::getRegistry()->addInstance('object_type_registry', $registryInstance);
}
// Return the instance
return $registryInstance;
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Bootstrap\FrameworkBootstrap;
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for ProtocolResolver
$protocolName = FrameworkBootstrap::getConfigurationInstance()->getConfigEntry('hub_communication_protocol_type');
// If there is no handler?
- if (Registry::getRegistry()->instanceExists($protocolName . '_protocol_resolver')) {
+ if (GenericRegistry::getRegistry()->instanceExists($protocolName . '_protocol_resolver')) {
// Get handler from registry
- $resolverInstance = Registry::getRegistry()->getInstance($protocolName . '_protocol_resolver');
+ $resolverInstance = GenericRegistry::getRegistry()->getInstance($protocolName . '_protocol_resolver');
} else {
// Get the handler instance
$resolverInstance = self::createObjectByConfiguredName($protocolName . '_protocol_resolver_class');
// Add it to the registry
- Registry::getRegistry()->addInstance($protocolName . '_protocol_resolver', $resolverInstance);
+ GenericRegistry::getRegistry()->addInstance($protocolName . '_protocol_resolver', $resolverInstance);
}
// Return the instance
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Task\Taskable;
/**
$factoryInstance = new ScannerObjectFactory();
// Get task handler instance
- $handlerInstance = Registry::getRegistry()->getInstance('task_handler');
+ $handlerInstance = GenericRegistry::getRegistry()->getInstance('task_handler');
// Get scanner type for given task instance by searching it in task handler
$scannerType = $handlerInstance->searchTask($taskInstance);
assert(!empty($scannerType));
// If there is no handler?
- if (Registry::getRegistry()->instanceExists('scanner_' . $scannerType)) {
+ if (GenericRegistry::getRegistry()->instanceExists('scanner_' . $scannerType)) {
// Get handler from registry
- $scannerInstance = Registry::getRegistry()->getInstance('scanner_' . $scannerType);
+ $scannerInstance = GenericRegistry::getRegistry()->getInstance('scanner_' . $scannerType);
} else {
// Get the scanner instance
$scannerInstance = ObjectFactory::createObjectByConfiguredName($scannerType);
// Add it to the registry
- Registry::getRegistry()->addInstance('scanner_' . $scannerType, $scannerInstance);
+ GenericRegistry::getRegistry()->addInstance('scanner_' . $scannerType, $scannerInstance);
}
// Return the instance
// Import framework stuff
use Org\Mxchange\CoreFramework\Bootstrap\FrameworkBootstrap;
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Socket\InvalidSocketException;
// Import SPL stuff
//* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('SOCKET-FACTORY: Trying to find a socket with registryKey=' . $registryKey);
// Is the key there?
- if (Registry::getRegistry()->instanceExists($registryKey)) {
+ if (GenericRegistry::getRegistry()->instanceExists($registryKey)) {
// Get container instance
- $socketInstance = Registry::getRegistry()->getInstance($registryKey);
+ $socketInstance = GenericRegistry::getRegistry()->getInstance($registryKey);
// Debug message
//* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('SOCKET-FACTORY: Using socket ' . $socketInstance->getSocketResource() . '(' . gettype($socketInstance->getSocketResource()) . ') from registry.');
$socketInstance = call_user_func($className . '::createConnectionFromPackageData', $packageData);
// Register it with the registry
- Registry::getRegistry()->addInstance($registryKey, $socketInstance);
+ GenericRegistry::getRegistry()->addInstance($registryKey, $socketInstance);
// Debug message
//* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('SOCKET-FACTORY: Socket is now registered in registry.');
$socketProtocol = $socketInstance->getSocketProtocol();
// Is the an iterator instance?
- if (!Registry::getRegistry()->instanceExists('pool_iterator_' . $socketProtocol)) {
+ if (!GenericRegistry::getRegistry()->instanceExists('pool_iterator_' . $socketProtocol)) {
// Create iterator instance
$iteratorInstance = $poolInstance->createListIteratorInstance($socketProtocol . '_pool');
// Now store it in registry
- Registry::getRegistry()->addInstance('pool_iterator', $iteratorInstance);
+ GenericRegistry::getRegistry()->addInstance('pool_iterator', $iteratorInstance);
} else {
// Get iterator from registry
- $iteratorInstance = Registry::getRegistry()->getInstance('pool_iterator_' . $socketProtocol);
+ $iteratorInstance = GenericRegistry::getRegistry()->getInstance('pool_iterator_' . $socketProtocol);
}
// Is it valid?
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for unit sources
*/
public static final function createUnitSourceInstance ($unitType) {
// Do we have cache?
- if (!Registry::getRegistry()->instanceExists($unitType . '_unit_source')) {
+ if (!GenericRegistry::getRegistry()->instanceExists($unitType . '_unit_source')) {
// Then construct the class' configuraton entry
$className = '' . $unitType . '_unit_source_class';
$sourceInstance = self::createObjectByConfiguredName($className);
// Add it to the registry
- Registry::getRegistry()->addInstance($unitType . '_unit_source', $sourceInstance);
+ GenericRegistry::getRegistry()->addInstance($unitType . '_unit_source', $sourceInstance);
} else {
// Get it from registry
- $sourceInstance = Registry::getRegistry()->getInstance($unitType . '_unit_source');
+ $sourceInstance = GenericRegistry::getRegistry()->getInstance($unitType . '_unit_source');
}
// For any purposes, return the source instance
return $sourceInstance;
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Task\Taskable;
/**
$factoryInstance = new UrlSourceObjectFactory();
// Get task handler instance
- $handlerInstance = Registry::getRegistry()->getInstance('task_handler');
+ $handlerInstance = GenericRegistry::getRegistry()->getInstance('task_handler');
// Get source type by looking for given task instance in task handler
$sourceType = $handlerInstance->searchTask($taskInstance);
assert(!empty($sourceType));
// If there is no handler?
- if (Registry::getRegistry()->instanceExists('source_' . $sourceType)) {
+ if (GenericRegistry::getRegistry()->instanceExists('source_' . $sourceType)) {
// Get handler from registry
- $sourceInstance = Registry::getRegistry()->getInstance('source_' . $sourceType);
+ $sourceInstance = GenericRegistry::getRegistry()->getInstance('source_' . $sourceType);
} else {
// Get the source instance
$sourceInstance = self::createObjectByConfiguredName($sourceType . '_class');
// Add it to the registry
- Registry::getRegistry()->addInstance('source_' . $sourceType, $sourceInstance);
+ GenericRegistry::getRegistry()->addInstance('source_' . $sourceType, $sourceInstance);
}
// Return the instance
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for crawler states
$stateInstance = self::createObjectByConfiguredName($className);
// Get crawler instance
- $crawlerInstance = Registry::getRegistry()->getInstance('crawler');
+ $crawlerInstance = GenericRegistry::getRegistry()->getInstance('crawler');
// Debug message
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('CRAWLER-STATE-FACTORY: Crawler state has changed from ' . $crawlerInstance->getPrintableState() . ' to ' . $stateInstance->getStateName() . '.');
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for cruncher states
$className = 'cruncher_' . $stateName . '_state_class';
// Get cruncher instance from registry
- $cruncherInstance = Registry::getRegistry()->getInstance('cruncher');
+ $cruncherInstance = GenericRegistry::getRegistry()->getInstance('cruncher');
// Get a class from that configuration entry
$stateInstance = self::createObjectByConfiguredName($className);
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for miner states
$className = 'miner_' . $stateName . '_state_class';
// Get miner instance
- $minerInstance = Registry::getRegistry()->getInstance('miner');
+ $minerInstance = GenericRegistry::getRegistry()->getInstance('miner');
// Get a class from that configuration entry
$stateInstance = self::createObjectByConfiguredName($className);
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A factory class for network packages
*/
public static final function createPackageTagsInstance () {
// Do we have an instance in the registry?
- if (Registry::getRegistry()->instanceExists('package_tags')) {
+ if (GenericRegistry::getRegistry()->instanceExists('package_tags')) {
// Then use this instance
- $packageInstance = Registry::getRegistry()->getInstance('package_tags');
+ $packageInstance = GenericRegistry::getRegistry()->getInstance('package_tags');
} else {
// Now prepare the tags instance
$packageInstance = self::createObjectByConfiguredName('package_tags_class');
// Set the instance in registry for further use
- Registry::getRegistry()->addInstance('package_tags', $packageInstance);
+ GenericRegistry::getRegistry()->addInstance('package_tags', $packageInstance);
}
// Return the instance
return $packageInstance;
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get task handler instance
- $handlerInstance = Registry::getRegistry()->getInstance('task_handler');
+ $handlerInstance = GenericRegistry::getRegistry()->getInstance('task_handler');
// Prepare a self-test task for the listeners
$taskInstance = ObjectFactory::createObjectByConfiguredName('node_announcement_task_class');
// Register it
$handlerInstance->registerTask('announcement', $taskInstance);
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
$proxyInstance = ObjectFactory::createObjectByConfiguredName('node_console_apt_proxy_class');
// Get a registry
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
// Set the app instance
$proxyInstance->setApplicationInstance($applicationInstance);
$proxyInstance->addExtraFilters($applicationInstance->getControllerInstance(), $responseInstance);
// Set the apt_proxy instance in registry
- Registry::getRegistry()->addInstance('apt_proxy', $proxyInstance);
+ GenericRegistry::getRegistry()->addInstance('apt_proxy', $proxyInstance);
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get node instance
- $proxyInstance = Registry::getRegistry()->getInstance('apt_proxy');
+ $proxyInstance = GenericRegistry::getRegistry()->getInstance('apt_proxy');
// Now output the teaser
$proxyInstance->outputConsoleTeaser();
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get apt-proxy instance
- $proxyInstance = Registry::getRegistry()->getInstance('apt_proxy');
+ $proxyInstance = GenericRegistry::getRegistry()->getInstance('apt_proxy');
// Now do something
$this->partialStub('Please implement this step.');
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get apt-proxy instance
- $proxyInstance = Registry::getRegistry()->getInstance('apt_proxy');
+ $proxyInstance = GenericRegistry::getRegistry()->getInstance('apt_proxy');
// Do some extra bootstrapping steps
$proxyInstance->doBootstrapping();
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get a apt-proxy instance
- $proxyInstance = Registry::getRegistry()->getInstance('apt_proxy');
+ $proxyInstance = GenericRegistry::getRegistry()->getInstance('apt_proxy');
// Set the flag
$proxyInstance->enableIsActive();
// Debug message
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('BOOTSTRAP: apt-proxy has been activated.');
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get chat instance
- $chatInstance = Registry::getRegistry()->getInstance('chat');
+ $chatInstance = GenericRegistry::getRegistry()->getInstance('chat');
// Now do something
$this->partialStub('Please implement this step.');
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get chat instance
- $chatInstance = Registry::getRegistry()->getInstance('chat');
+ $chatInstance = GenericRegistry::getRegistry()->getInstance('chat');
// Do some extra bootstrapping steps
$chatInstance->doBootstrapping();
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get a chat instance
- $chatInstance = Registry::getRegistry()->getInstance('chat');
+ $chatInstance = GenericRegistry::getRegistry()->getInstance('chat');
// Set the flag
$chatInstance->enableIsActive();
// Debug message
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('BOOTSTRAP: The chat console has been activated.');
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get crawler instance
- $crawlerInstance = Registry::getRegistry()->getInstance('crawler');
+ $crawlerInstance = GenericRegistry::getRegistry()->getInstance('crawler');
// Now do something
$this->partialStub('Please implement this step.');
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get crawler instance
- $crawlerInstance = Registry::getRegistry()->getInstance('crawler');
+ $crawlerInstance = GenericRegistry::getRegistry()->getInstance('crawler');
// Do some extra bootstrapping steps
$crawlerInstance->doBootstrapping();
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get a crawler instance
- $crawlerInstance = Registry::getRegistry()->getInstance('crawler');
+ $crawlerInstance = GenericRegistry::getRegistry()->getInstance('crawler');
// Set the flag
$crawlerInstance->enableIsActive();
// Debug message
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('BOOTSTRAP: The crawler has been activated.');
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get cruncher instance
- $cruncherInstance = Registry::getRegistry()->getInstance('cruncher');
+ $cruncherInstance = GenericRegistry::getRegistry()->getInstance('cruncher');
// Now do something
$this->partialStub('Please implement this step.');
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get cruncher instance
- $cruncherInstance = Registry::getRegistry()->getInstance('cruncher');
+ $cruncherInstance = GenericRegistry::getRegistry()->getInstance('cruncher');
// Init all buffer queues
$cruncherInstance->initBufferQueues();
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get cruncher instance
- $cruncherInstance = Registry::getRegistry()->getInstance('cruncher');
+ $cruncherInstance = GenericRegistry::getRegistry()->getInstance('cruncher');
// Do some extra bootstrapping steps
$cruncherInstance->doBootstrapping();
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get a cruncher instance
- $cruncherInstance = Registry::getRegistry()->getInstance('cruncher');
+ $cruncherInstance = GenericRegistry::getRegistry()->getInstance('cruncher');
// Set the flag
$cruncherInstance->enableIsActive();
// Debug message
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('BOOTSTRAP: The cruncher has been activated.');
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get miner instance
- $minerInstance = Registry::getRegistry()->getInstance('miner');
+ $minerInstance = GenericRegistry::getRegistry()->getInstance('miner');
// Now do something
$this->partialStub('Please implement this step.');
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get miner instance
- $minerInstance = Registry::getRegistry()->getInstance('miner');
+ $minerInstance = GenericRegistry::getRegistry()->getInstance('miner');
// Init all buffer queues
$minerInstance->initBufferQueues();
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get miner instance
- $minerInstance = Registry::getRegistry()->getInstance('miner');
+ $minerInstance = GenericRegistry::getRegistry()->getInstance('miner');
// Do some extra bootstrapping steps
$minerInstance->doBootstrapping();
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get a miner instance
- $minerInstance = Registry::getRegistry()->getInstance('miner');
+ $minerInstance = GenericRegistry::getRegistry()->getInstance('miner');
// Set the flag
$minerInstance->enableIsActive();
// Debug message
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('BOOTSTRAP: The miner has been activated.');
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
$chatInstance = ObjectFactory::createObjectByConfiguredName('node_console_chat_class');
// Get a registry
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
// Set the app instance
$chatInstance->setApplicationInstance($applicationInstance);
$chatInstance->addExtraFilters($applicationInstance->getControllerInstance(), $responseInstance);
// Set the chat instance in registry
- Registry::getRegistry()->addInstance('chat', $chatInstance);
+ GenericRegistry::getRegistry()->addInstance('chat', $chatInstance);
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get node instance
- $chatInstance = Registry::getRegistry()->getInstance('chat');
+ $chatInstance = GenericRegistry::getRegistry()->getInstance('chat');
// Now output the teaser
$chatInstance->outputConsoleTeaser();
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
$crawlerInstance = ObjectFactory::createObjectByConfiguredName('node_console_crawler_class');
// Get a registry
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
// Set the app instance
$crawlerInstance->setApplicationInstance($applicationInstance);
// Add crawler-specific filters
$crawlerInstance->addExtraFilters($applicationInstance->getControllerInstance(), $responseInstance);
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get node instance
- $crawlerInstance = Registry::getRegistry()->getInstance('crawler');
+ $crawlerInstance = GenericRegistry::getRegistry()->getInstance('crawler');
// Now output the teaser
$crawlerInstance->outputConsoleTeaser();
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
$cruncherInstance = ObjectFactory::createObjectByName($className);
// Get a registry
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
// Set the app instance
$cruncherInstance->setApplicationInstance($applicationInstance);
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get node instance
- $cruncherInstance = Registry::getRegistry()->getInstance('cruncher');
+ $cruncherInstance = GenericRegistry::getRegistry()->getInstance('cruncher');
// Now output the teaser
$cruncherInstance->outputConsoleTeaser();
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
$minerInstance = ObjectFactory::createObjectByName($className);
// Get a registry
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
// Set the app instance
$minerInstance->setApplicationInstance($applicationInstance);
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get node instance
- $minerInstance = Registry::getRegistry()->getInstance('miner');
+ $minerInstance = GenericRegistry::getRegistry()->getInstance('miner');
// Now output the teaser
$minerInstance->outputConsoleTeaser();
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get node instance
- $proxyInstance = Registry::getRegistry()->getInstance('apt_proxy');
+ $proxyInstance = GenericRegistry::getRegistry()->getInstance('apt_proxy');
// Shutdown the apt-proxy. This should be the last line
$proxyInstance->doShutdown();
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get node instance
- $chatInstance = Registry::getRegistry()->getInstance('chat');
+ $chatInstance = GenericRegistry::getRegistry()->getInstance('chat');
// Shutdown the chat. This should be the last line
$chatInstance->doShutdown();
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get node instance
- $crawlerInstance = Registry::getRegistry()->getInstance('crawler');
+ $crawlerInstance = GenericRegistry::getRegistry()->getInstance('crawler');
// Shutdown the crawler. This should be the last line
$crawlerInstance->doShutdown();
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get node instance
- $cruncherInstance = Registry::getRegistry()->getInstance('cruncher');
+ $cruncherInstance = GenericRegistry::getRegistry()->getInstance('cruncher');
// Shutdown the cruncher. This should be the last line
$cruncherInstance->doShutdown();
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get node instance
- $minerInstance = Registry::getRegistry()->getInstance('miner');
+ $minerInstance = GenericRegistry::getRegistry()->getInstance('miner');
// Shutdown the miner. This should be the last line
$minerInstance->doShutdown();
// Import framework stuff
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get task handler instance
- $handlerInstance = Registry::getRegistry()->getInstance('task_handler');
+ $handlerInstance = GenericRegistry::getRegistry()->getInstance('task_handler');
// Shutdown the task manager and all its registered tasks
$handlerInstance->doShutdown();
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get apt-proxy instance
- //$chatInstance = Registry::getRegistry()->getInstance('chat');
+ //$chatInstance = GenericRegistry::getRegistry()->getInstance('chat');
// Get a new task handler instance
$handlerInstance = ObjectFactory::createObjectByConfiguredName('task_handler_class');
// Put the task handler in registry
- Registry::getRegistry()->addInstance('task_handler', $handlerInstance);
+ GenericRegistry::getRegistry()->addInstance('task_handler', $handlerInstance);
/*
* Register all tasks:
$taskInstance = ObjectFactory::createObjectByConfiguredName('apt_proxy_listener_task_class');
$handlerInstance->registerTask('apt_proxy_listener', $taskInstance);
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get chat instance
- //$chatInstance = Registry::getRegistry()->getInstance('chat');
+ //$chatInstance = GenericRegistry::getRegistry()->getInstance('chat');
// Get a new task handler instance
$handlerInstance = ObjectFactory::createObjectByConfiguredName('task_handler_class');
// Put the task handler in registry
- Registry::getRegistry()->addInstance('task_handler', $handlerInstance);
+ GenericRegistry::getRegistry()->addInstance('task_handler', $handlerInstance);
/*
* Register all tasks:
$taskInstance = ObjectFactory::createObjectByConfiguredName('chat_telnet_listener_task_class');
$handlerInstance->registerTask('chat_telnet_listener', $taskInstance);
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get crawler instance
- $crawlerInstance = Registry::getRegistry()->getInstance('crawler');
+ $crawlerInstance = GenericRegistry::getRegistry()->getInstance('crawler');
// Get a new task handler instance
$handlerInstance = ObjectFactory::createObjectByConfiguredName('task_handler_class');
// Put the task handler in registry
- Registry::getRegistry()->addInstance('task_handler', $handlerInstance);
+ GenericRegistry::getRegistry()->addInstance('task_handler', $handlerInstance);
/*
* Register all tasks:
$taskInstance = ObjectFactory::createObjectByConfiguredName('crawler_uploaded_list_scanner_task_class');
$handlerInstance->registerTask('crawler_uploaded_list_scanner', $taskInstance);
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get cruncher instance
- //$cruncherInstance = Registry::getRegistry()->getInstance('cruncher');
+ //$cruncherInstance = GenericRegistry::getRegistry()->getInstance('cruncher');
// Get a new task handler instance
$handlerInstance = ObjectFactory::createObjectByConfiguredName('task_handler_class');
// Put the task handler in registry
- Registry::getRegistry()->addInstance('task_handler', $handlerInstance);
+ GenericRegistry::getRegistry()->addInstance('task_handler', $handlerInstance);
// Register all tasks:
//
$taskInstance = ObjectFactory::createObjectByConfiguredName('cruncher_key_producer_task_class');
$handlerInstance->registerTask('cruncher_key_producer', $taskInstance);
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
*/
public function execute (Requestable $requestInstance, Responseable $responseInstance) {
// Get miner instance
- //$minerInstance = Registry::getRegistry()->getInstance('miner');
+ //$minerInstance = GenericRegistry::getRegistry()->getInstance('miner');
// Get a new task handler instance
$handlerInstance = ObjectFactory::createObjectByConfiguredName('task_handler_class');
// Put the task handler in registry
- Registry::getRegistry()->addInstance('task_handler', $handlerInstance);
+ GenericRegistry::getRegistry()->addInstance('task_handler', $handlerInstance);
// Register all tasks:
//
$taskInstance = ObjectFactory::createObjectByConfiguredName('miner_node_communicator_task_class');
$handlerInstance->registerTask('miner_node_communicator', $taskInstance);
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Filter\Filterable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
$handlerInstance = ObjectFactory::createObjectByConfiguredName('task_handler_class');
// Put the task handler in registry
- Registry::getRegistry()->addInstance('task_handler', $handlerInstance);
+ GenericRegistry::getRegistry()->addInstance('task_handler', $handlerInstance);
// Prepare a package-tags initialization task for the listeners
$taskInstance = ObjectFactory::createObjectByConfiguredName('node_package_tags_init_task_class');
use Org\Shipsimu\Hub\Node\BaseHubNode;
// Import framework stuff
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Registry\Registerable;
-use Org\Mxchange\CoreFramework\Registry\Registry;
/**
* A AnnouncementAnswerOkay handler
DhtObjectFactory::createDhtInstance('node')->registerNodeByMessageData($messageData, $this, TRUE);
// Get handler instance
- $handlerInstance = Registry::getRegistry()->getInstance('task_handler');
+ $handlerInstance = GenericRegistry::getRegistry()->getInstance('task_handler');
// Generate DHT bootstrap task
$taskInstance = ObjectFactory::createObjectByConfiguredName('node_dht_late_bootstrap_task_class');
// Remove temporay configuration
$this->getConfigInstance()->unsetConfigEntry(NodeDistributedHashTableDatabaseWrapper::DB_COLUMN_ACCEPTED_OBJECTS);
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Generic\FrameworkInterface;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Registry\Registerable;
use Org\Mxchange\CoreFramework\Visitor\Visitable;
use Org\Mxchange\CoreFramework\Visitor\Visitor;
$this->setPackageInstance($packageInstance);
// Register this connection helper
- Registry::getRegistry()->addInstance('connection', $this);
+ GenericRegistry::getRegistry()->addInstance('connection', $this);
// Get the fragmenter instance
$fragmenterInstance = FragmenterFactory::createFragmenterInstance('package');
// Import framework stuff
use Org\Mxchange\CoreFramework\Database\Updateable;
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A general hub miner class
*/
private function initMiner () {
// Add own instance to registry
- Registry::getRegistry()->addInstance('miner', $this);
+ GenericRegistry::getRegistry()->addInstance('miner', $this);
// Init the state
MinerStateFactory::createMinerStateInstanceByName('init');
use Org\Mxchange\CoreFramework\Bootstrap\FrameworkBootstrap;
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Handler\Task\HandleableTask;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Registry\Registerable;
/**
*/
public function addExtraNodeFilters () {
// Get the application instance from registry
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
// Get the controller from the application
$controllerInstance = $applicationInstance->getControllerInstance();
use Org\Mxchange\CoreFramework\Factory\Database\Wrapper\DatabaseWrapperFactory;
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Generic\NullPointerException;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Request\Requestable;
use Org\Mxchange\CoreFramework\Response\Responseable;
use Org\Mxchange\CoreFramework\Task\Taskable;
$this->setCryptoInstance($cryptoInstance);
// Set the node instance in registry
- Registry::getRegistry()->addInstance('node', $this);
+ GenericRegistry::getRegistry()->addInstance('node', $this);
// Init state which sets the state to 'init'
$this->initState();
} // END - if
// Get the controller here
- $controllerInstance = Registry::getRegistry()->getInstance('controller');
+ $controllerInstance = GenericRegistry::getRegistry()->getInstance('controller');
// Run all filters for the hub activation
$controllerInstance->executeActivationFilters($requestInstance, $responseInstance);
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Handler\Task\HandleableTask;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Registry\Registerable;
/**
*/
public function addExtraNodeFilters () {
// Get the application instance from registry
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
// Get the controller from the application
$controllerInstance = $applicationInstance->getControllerInstance();
public function addExtraTasks (HandleableTask $handlerInstance) {
$this->partialStub('Please add some tasks or empty this method.');
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Handler\Task\HandleableTask;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Registry\Registerable;
/**
*/
public function addExtraNodeFilters () {
// Get the application instance from registry
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
// Get the controller from the application
$controllerInstance = $applicationInstance->getControllerInstance();
public function addExtraTasks (HandleableTask $handlerInstance) {
$this->partialStub('Please add some tasks or empty this method.');
}
-}
-// [EOF]
-?>
+}
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Handler\Task\HandleableTask;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Registry\Registerable;
/**
*/
public function addExtraNodeFilters () {
// Get the application instance from registry
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
// Get the controller from the application
$controllerInstance = $applicationInstance->getControllerInstance();
public function addExtraTasks (HandleableTask $handlerInstance) {
$this->partialStub('Please add some tasks or empty this method.');
}
-}
-// [EOF]
-?>
+}
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Factory\Registry\Socket\SocketRegistryFactory;
use Org\Mxchange\CoreFramework\Feature\FrameworkFeature;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Registry\Registerable;
use Org\Mxchange\CoreFramework\Socket\InvalidSocketException;
use Org\Mxchange\CoreFramework\Visitor\Visitable;
//* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('NETWORK-PACKAGE: Reached line ' . __LINE__ . ' after discoverSocket() has been called.');
// Get the connection helper from registry
- $helperInstance = Registry::getRegistry()->getInstance('connection');
+ $helperInstance = GenericRegistry::getRegistry()->getInstance('connection');
// Debug message
//* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('NETWORK-PACKAGE: stateInstance=' . $helperInstance->getStateInstance());
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Visitor\Visitable;
use Org\Mxchange\CoreFramework\Visitor\Visitor;
$visitorInstance->visitPool($this);
// Do we have a registry instance for this visitor's iterator?
- if (Registry::getRegistry()->instanceExists($visitorInstance->getVisitorMode() . '_pool_iterator')) {
+ if (GenericRegistry::getRegistry()->instanceExists($visitorInstance->getVisitorMode() . '_pool_iterator')) {
// Get the instance from registry
- $iteratorInstance = Registry::getRegistry()->getInstance($visitorInstance->getVisitorMode() . '_pool_iterator');
+ $iteratorInstance = GenericRegistry::getRegistry()->getInstance($visitorInstance->getVisitorMode() . '_pool_iterator');
} else {
// Get a new iterator instance
$iteratorInstance = ObjectFactory::createObjectByConfiguredName($visitorInstance->getVisitorMode() . '_pool_iterator_class', array($this->getPoolEntriesInstance()));
// Add it to the registry
- Registry::getRegistry()->addInstance($visitorInstance->getVisitorMode() . '_pool_iterator', $iteratorInstance);
+ GenericRegistry::getRegistry()->addInstance($visitorInstance->getVisitorMode() . '_pool_iterator', $iteratorInstance);
}
// Is it valid?
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A general Producer class
$this->initProducer();
// Get miner instance
- $minerInstance = Registry::getRegistry()->getInstance('miner');
+ $minerInstance = GenericRegistry::getRegistry()->getInstance('miner');
// Change state to next state
$minerInstance->blockProducerHasInitialized($this);
// Import framework stuff
use Org\Mxchange\CoreFramework\Factory\Template\XmlTemplateEngineFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
/**
* A Package tags class
/* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('TAGS: Initializing object registry - CALLED!');
// Get the application instance
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
// Get a XML template instance
$templateInstance = XmlTemplateEngineFactory::createXmlTemplateEngineInstance('node_object_registry_template_class');
use Org\Shipsimu\Hub\Factory\Communicator\CommunicatorFactory;
// Import framework stuff
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Task\BaseTask;
use Org\Mxchange\CoreFramework\Task\Taskable;
use Org\Mxchange\CoreFramework\Visitor\Visitable;
$communicatorInstance = CommunicatorFactory::createCommunicatorInstance('crawler_node_communicator_class', 'node');
// Get the current crawler state from registry
- $stateInstance = Registry::getRegistry()->getInstance('crawler')->getStateInstance();
+ $stateInstance = GenericRegistry::getRegistry()->getInstance('crawler')->getStateInstance();
// Debug message
/* DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('CRAWLER-NODE-COMMUNICATOR-TASK: Executing stateInstance=' . $stateInstance->__toString());
public function doShutdown () {
self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('CRAWLER-NODE-COMMUNICATOR-TASK: Shutting down...');
}
-}
-// [EOF]
-?>
+}
$producerInstance = ProducerFactory::createProducerInstance('cruncher_key_producer_class', 'key');
// Get the current cruncher state from registry
- $stateInstance = Registry::getRegistry()->getInstance('cruncher')->getStateInstance();
+ $stateInstance = GenericRegistry::getRegistry()->getInstance('cruncher')->getStateInstance();
// Debug message
/* DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('CRUNCHER-KEY-PRODUCER-TASK: Executing stateInstance=' . $stateInstance->__toString());
$producerInstance = ProducerFactory::createProducerInstance('cruncher_test_unit_producer_class', 'test_unit');
// Get the current cruncher state from registry
- $stateInstance = Registry::getRegistry()->getInstance('cruncher')->getStateInstance();
+ $stateInstance = GenericRegistry::getRegistry()->getInstance('cruncher')->getStateInstance();
// Debug message
/* DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('CRUNCHER-TEST-UNIT-PRODUCER-TASK: Executing stateInstance=' . $stateInstance->__toString());
namespace Org\Shipsimu\Hub\Cruncher\Task\Fetcher\WorkUnit;
// Import framework stuff
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Task\BaseTask;
use Org\Mxchange\CoreFramework\Task\Taskable;
use Org\Mxchange\CoreFramework\Visitor\Visitable;
*
* Please report any bugs you encounter to me.
*/
- Registry::getRegistry()->getInstance('cruncher')->doFetchWorkUnits();
+ GenericRegistry::getRegistry()->getInstance('cruncher')->doFetchWorkUnits();
}
/**
namespace Org\Shipsimu\Hub\Miner\Task\Fetcher\Block;
// Import framework stuff
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Task\BaseTask;
use Org\Mxchange\CoreFramework\Task\Taskable;
use Org\Mxchange\CoreFramework\Visitor\Visitable;
*
* Please report any bugs you encounter to me.
*/
- Registry::getRegistry()->getInstance('miner')->doSearchForBlocks();
+ GenericRegistry::getRegistry()->getInstance('miner')->doSearchForBlocks();
}
/**
namespace Org\Shipsimu\Hub\Miner\Task\Producer\GenesisBlock;
// Import framework stuff
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Task\BaseTask;
use Org\Mxchange\CoreFramework\Task\Taskable;
use Org\Mxchange\CoreFramework\Visitor\Visitable;
$producerInstance = ProducerFactory::createProducerInstance('miner_real_genesis_block_producer_class', 'real_unit');
// Get the current miner state from registry
- $stateInstance = Registry::getRegistry()->getInstance('miner')->getStateInstance();
+ $stateInstance = GenericRegistry::getRegistry()->getInstance('miner')->getStateInstance();
// Debug message
/* DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('MINER-GENESIS-BLOCK-PRODUCER-TASK: Executing stateInstance=' . $stateInstance->__toString());
$producerInstance = ProducerFactory::createProducerInstance('miner_test_genesis_block_producer_class', 'test_unit');
// Get the current miner state from registry
- $stateInstance = Registry::getRegistry()->getInstance('miner')->getStateInstance();
+ $stateInstance = GenericRegistry::getRegistry()->getInstance('miner')->getStateInstance();
// Debug message
/* DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('MINER-TEST-GENESIS-BLOCK-PRODUCER-TASK: Executing stateInstance=' . $stateInstance->__toString());
use Org\Mxchange\CoreFramework\Bootstrap\FrameworkBootstrap;
use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
use Org\Mxchange\CoreFramework\Factory\Template\XmlTemplateEngineFactory;
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Template\Engine\BaseTemplateEngine;
/**
$this->typePrefix = $typePrefix;
// Get template instance
- $applicationInstance = Registry::getRegistry()->getInstance('app');
+ $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
// Determine base path
$templateBasePath = $this->getConfigInstance()->getConfigEntry('application_base_path') . FrameworkBootstrap::getRequestInstance()->getRequestElement('app') . '/';
use Org\Shipsimu\Hub\Template\Engine\Xml\BaseXmlTemplateEngine;
// Import framework stuff
-use Org\Mxchange\CoreFramework\Registry\Registry;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
use Org\Mxchange\CoreFramework\Registry\Registerable;
use Org\Mxchange\CoreFramework\Template\CompileableTemplate;
-Subproject commit de0eb5a71c8f65df71712ba9c5cd7092baa8d980
+Subproject commit bed81d8edc3673951a1ee57f38f5a1a07c417b69