|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.ca.jcs.cfg.MetaPluginConfig
public class MetaPluginConfig
Configuration bean that allows mapping of metadata properties (and optionally their values) to the plug-in classes required to handle them.
| Constructor Summary | |
|---|---|
MetaPluginConfig()
|
|
| Method Summary | |
|---|---|
Object |
createClassPlugin(MetaObjectClassMapping classMap)
Create a plugin looking first for a constructor taking classMap as an argument. |
Object |
createPlugin(Object consArg)
Calls createPlugin(Object, Class) assuming constructor
argument is concrete class of consArg. |
Object |
createPlugin(Object consArg1,
Class consArgClass1)
Create a plug-in first looking for a constructor taking consArg1 (with class as defined in
constructor argument passed in). |
Object |
createPluginFlexibleCons(Object consArg1,
Class consArgClass1,
Object consArg2,
Class consArgClass2)
Create a plug-in first looking for a constructor taking both consArg1 and consArg2 (with classes as defined in
constructor arguments passed in), and secondly looking for constructor taking only consArg2 by itself). |
Object |
createPropertyPlugin(MetaObjectClassMapping classMap,
DataModelProperty prop)
Create a plugin looking first for a constructor taking both classMap and prop as arguments, otherwise
falling back one taking just prop as an argument. |
List<String> |
getMetadataPropNames()
|
Class |
getPluginClass()
|
Object |
getPluginConfig()
An optional object can be passed to the plugin in its constructor, allowing it's behaviour to be modulated for a specific plugin entry (eg whether it should be considered active by default etc). |
String |
getType()
Config can either be triggered using a type (eg "BOOL", "COMPOUND_VALUE_CLASS_REF" or "COMPOUND_VALUE_CLASS_REF:MyClass") or by using metadataPropNames as triggers. |
boolean |
isApplicableToAllProps()
Plugin application isn't driven by metadata property list, but rather its constructor is called for every datamodel property and needs to veto those it doesn't apply to by throwing a plug-in not required exception. |
boolean |
isApplicableToType(DataModelValue val)
|
boolean |
isOverrideValuePlugin()
Deprecated. |
void |
setMetadataPropNames(List<String> metadataPropNames)
|
void |
setOverrideValuePlugin(boolean overridesValuePlugin)
Deprecated. |
void |
setPluginClass(Class pluginClass)
|
void |
setPluginConfig(Object pluginConfig)
|
void |
setType(String type)
|
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public MetaPluginConfig()
| Method Detail |
|---|
@Deprecated public boolean isOverrideValuePlugin()
MetaDataDefs.MD_IS_STORE_SYMBOLIC which affect the plug-in's behaviour.
@Deprecated public void setOverrideValuePlugin(boolean overridesValuePlugin)
public boolean isApplicableToAllProps()
public String getType()
public void setType(String type)
public List<String> getMetadataPropNames()
public void setMetadataPropNames(List<String> metadataPropNames)
public Class getPluginClass()
public void setPluginClass(Class pluginClass)
public Object getPluginConfig()
server_jcs.xml file, or null if none was.public void setPluginConfig(Object pluginConfig)
public Object createPluginFlexibleCons(Object consArg1,
Class consArgClass1,
Object consArg2,
Class consArgClass2)
consArg1 and consArg2 (with classes as defined in
constructor arguments passed in), and secondly looking for constructor taking only consArg2 by itself). If this class has a
specialized configuration object to be passed in to the plugin then it is passed in as the first argument.
consArg1 - Optional argument to constructor.consArgClass1 - Defined class for constructor argument matching consArg1 (may be defined as a base class instead of just consArg1.getClass())consArg2 - Mandatory argument to constructor.consArgClass2 - Defined class for constructor argument matching consArg2 (may be defined as a base class instead of just consArg2.getClass())
PluginNotRequiredException after
performing analysis of metadata.
public Object createPlugin(Object consArg1,
Class consArgClass1)
consArg1 (with class as defined in
constructor argument passed in). If this class has a
specialized configuration object to be passed in to the plugin then it is passed in as the first argument.
consArg1 - Optional argument to constructor.consArgClass1 - Defined class for constructor argument matching obj1 (may be defined as a base class instead of just obj1.getClass())
PluginNotRequiredException after
performing analysis of metadata.public Object createPlugin(Object consArg)
createPlugin(Object, Class) assuming constructor
argument is concrete class of consArg.
public Object createPropertyPlugin(MetaObjectClassMapping classMap,
DataModelProperty prop)
classMap and prop as arguments, otherwise
falling back one taking just prop as an argument.
classMap - Contains metadata for whole object class which defined prop.prop - Property which plugin may be required (plugins constructor may veto).
public Object createClassPlugin(MetaObjectClassMapping classMap)
classMap as an argument.
classMap - Contains metadata for whole object class which defined prop.
public boolean isApplicableToType(DataModelValue val)
public String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||