public class ClientConfigurationFactory
extends com.streamscape.sef.dispatcher.AbstractFabricContextFactory
Title: Service Event Fabric Runtime
Description: Client Configuration Factory allows users to work with client factories.
Client factories are managed objects that contain information required to instantiate user defined network connections within the Fabric Runtime. Developers may create their own implementations that allow them to register arbitrary transport providers. This factory will not function without a properly initialized
RuntimeContext
. It allows users to create default or empty configuration object so that
they may be programmatically populated, and to load or save such configuration objects using the
persistence mechanism that is configured with the Runtime Context
.
Copyright: Copyright (c) 2010
Company: StreamScape Technologies
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CONFIG_EXISTS |
static java.lang.String |
DEFAULT_CONNECTION_FACTORY |
static java.lang.String |
PROTOTYPE |
static java.lang.String |
SHOW_CONNECTION_PANEL |
DEFAULT_SERIAL_VERSION_ID
Constructor and Description |
---|
ClientConfigurationFactory(com.streamscape.repository.RepositoryContext repositoryContext) |
Modifier and Type | Method and Description |
---|---|
static ClientFactory |
createDefaultFactory(FabricComponent component,
java.lang.String factoryType,
java.lang.String className,
java.lang.String url)
Creates a new default
ClientFactory object. |
static ClientFactory |
createFactory(FabricComponent component,
java.lang.String factoryType,
java.lang.String factoryName,
java.lang.String providerClass,
java.lang.String url,
boolean isTransient) |
static ClientFactory |
createFactory(FabricComponent component,
java.lang.String factoryType,
java.lang.String factoryName,
java.lang.String providerClass,
java.lang.String url,
boolean isTransient,
boolean withLoad)
A constructor that creates a
Client Factory Object of a specific type. |
static boolean |
existsClientFactory(java.lang.String factoryName,
java.lang.String factoryType)
Returns
true if the transport factory exists. |
static ClientFactory |
loadFactoryObject(FabricComponent component,
java.lang.String factoryName,
java.lang.String factoryType,
boolean isTransient) |
static ClientFactory |
loadFactoryObject(FabricComponent component,
java.lang.String workingDir,
java.lang.String factoryType,
java.lang.String factoryName,
boolean isTransient)
Loads a
Client Factory object from the file system and returns it as a public interface. |
static void |
saveFactoryObject(ClientFactory cfo)
Saves the transport factory to persistence.
|
static void |
saveFactoryObject(java.lang.String workingDir,
ClientFactory cfo)
Saves the client factory object to a working directory specified.
|
getContext, getContextType, hasContext
clone, getSerialVersionUID
public static final java.lang.String PROTOTYPE
public static final java.lang.String SHOW_CONNECTION_PANEL
public static final java.lang.String DEFAULT_CONNECTION_FACTORY
public static final java.lang.String CONFIG_EXISTS
public ClientConfigurationFactory(com.streamscape.repository.RepositoryContext repositoryContext)
public static ClientFactory createDefaultFactory(FabricComponent component, java.lang.String factoryType, java.lang.String className, java.lang.String url) throws ClientConfigurationException
ClientFactory
object.component
- FabricComponentfactoryType
- StringclassName
- Stringurl
- StringClientConfigurationException
public static ClientFactory createFactory(FabricComponent component, java.lang.String factoryType, java.lang.String factoryName, java.lang.String providerClass, java.lang.String url, boolean isTransient, boolean withLoad) throws ClientConfigurationException
Client Factory Object
of a specific type.component
- FabricComponentfactoryType
- StringfactoryName
- StringproviderClass
- Stringurl
- StringisTransient
- booleanClientConfigurationException
public static ClientFactory createFactory(FabricComponent component, java.lang.String factoryType, java.lang.String factoryName, java.lang.String providerClass, java.lang.String url, boolean isTransient) throws ClientConfigurationException
ClientConfigurationException
public static boolean existsClientFactory(java.lang.String factoryName, java.lang.String factoryType) throws RepositoryException, ClientConfigurationException
true
if the transport factory exists.factoryName
- StringfactoryType
- StringRepositoryException
ClientConfigurationException
public static ClientFactory loadFactoryObject(FabricComponent component, java.lang.String factoryName, java.lang.String factoryType, boolean isTransient) throws RepositoryException, ClientConfigurationException
public static ClientFactory loadFactoryObject(FabricComponent component, java.lang.String workingDir, java.lang.String factoryType, java.lang.String factoryName, boolean isTransient) throws ClientConfigurationException
Client Factory
object from the file system and returns it as a public interface.
If a Class Loader
is specified it will be set on the object and used to instantiate
inner classes and perform factory related operations. If set to null
the object
will utilize the default on-thread class loader.
Typical use implements a two stage loading technique. First the package that contains all the
relevant JAR files is loaded. This may be a Transport Package or a different
one (for instance a service package) and it returns the class loader that references all the
critical libraries. The resulting class loader may then be passed to the load method ensuring
that the factory can access all the necessary classes and archive members.component
- FabricComponentworkingDir
- StringfactoryType
- StringfactoryName
- StringisTransient
- booleanClientConfigurationException
public static void saveFactoryObject(ClientFactory cfo) throws ClientConfigurationException, RuntimeContextException
cfo
- ClientFactoryClientConfigurationException
RuntimeContextException
public static void saveFactoryObject(java.lang.String workingDir, ClientFactory cfo) throws ClientConfigurationException, RuntimeContextException
workingDir
- Stringcfo
- ClientFactoryClientConfigurationException
RuntimeContextException
Copyright © 2015-2024 StreamScape Technologies. All rights reserved.