org.objectweb.fractal.fraclet
Class CompositeDefinitionPlugin

java.lang.Object
  extended byorg.generama.Plugin
      extended byorg.generama.defaults.QDoxPlugin
          extended byorg.objectweb.fractal.fraclet.FractalPlugin
              extended byorg.objectweb.fractal.fraclet.PrimitiveDefinitionPlugin
                  extended byorg.objectweb.fractal.fraclet.CompositeDefinitionPlugin
All Implemented Interfaces:
org.picocontainer.Startable

public class CompositeDefinitionPlugin
extends PrimitiveDefinitionPlugin

XDoclet plugin applied in conjunction with the FractalAdlPlugin.jelly template to generate primitive component descriptor file.

Version:
$Revision: 1.1 $
Author:
Romain Rouvoy

Field Summary
protected static String ASSEMBLY_SUFFIX
           
 
Fields inherited from class org.objectweb.fractal.fraclet.PrimitiveDefinitionPlugin
ADL_PREFIX, CONTENT_PREFIX, DEFINITION_SEPARATOR
 
Fields inherited from class org.objectweb.fractal.fraclet.FractalPlugin
AC_NAME, ATTR_CTRL, ATTR_NAME, BC_NAME, FC_CONTROL, ITF_NAME, LOG_NAME, OBJECT, RC_NAME
 
Fields inherited from class org.generama.defaults.QDoxPlugin
metadataProvider
 
Fields inherited from class org.generama.Plugin
DONTEDIT, writerMapper
 
Constructor Summary
CompositeDefinitionPlugin(JellyTemplateEngine jelly, QDoxCapableMetadataProvider qdox, WriterMapper writer)
          Composite definition generator for abstract composite.
 
Method Summary
protected  String extendsElement(JavaClass cls)
          Adds a definition extended.
 JavaClass interfaceClass(String name)
          Provides the instance of the class element named name.
 String parameters(JavaClass cls)
          Provides the list of parameters of a component.
 boolean shouldGenerate(Object cls)
          param cls the java class source file parsed.
 
Methods inherited from class org.objectweb.fractal.fraclet.PrimitiveDefinitionPlugin
argumentsDefinition, attributeValue, contentClass, extendsDefinition, interfaceSignature, primitiveDefinition
 
Methods inherited from class org.objectweb.fractal.fraclet.FractalPlugin
attributeController, attributeName, attributes, bindingName, bindings, bindingSignature, extend, fields, fullname, hasAttributes, hasBindings, hasGlue, hasLogger, hasReflects, isAttributeController, isComponent, isController, isInterface, isPrimitive, logger, loggerName, name, packagePrefix, reflects, superAttributeController
 
Methods inherited from class org.generama.defaults.QDoxPlugin
getMetadata, getMetadataProvider, setRestrictedpath
 
Methods inherited from class org.generama.Plugin
assertTrue, getContextObjects, getDestdirFile, getDestinationFilename, getDestinationPackage, getEncoding, getOutputValidator, getPackageName, getWriterMapper, isEmpty, isMultioutput, isValidate, populateContextMap, preGenerate, setDestdir, setEncoding, setFileregex, setFilereplace, setMultioutput, setOutputValidator, setPackageregex, setPackagereplace, setValidate, start, stop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ASSEMBLY_SUFFIX

protected static final String ASSEMBLY_SUFFIX
See Also:
Constant Field Values
Constructor Detail

CompositeDefinitionPlugin

public CompositeDefinitionPlugin(JellyTemplateEngine jelly,
                                 QDoxCapableMetadataProvider qdox,
                                 WriterMapper writer)
Composite definition generator for abstract composite.

Parameters:
jelly - the jelly XML template engine.
qdox - the qdox java model provider.
writer - the file writer mapper.
Method Detail

shouldGenerate

public boolean shouldGenerate(Object cls)
param cls the java class source file parsed.

Overrides:
shouldGenerate in class PrimitiveDefinitionPlugin
Returns:
true if a FractalADL file should be generated.

extendsElement

protected String extendsElement(JavaClass cls)
Description copied from class: PrimitiveDefinitionPlugin
Adds a definition extended.

Overrides:
extendsElement in class PrimitiveDefinitionPlugin
Parameters:
cls - the java class source file parsed.
Returns:
the associated extend clause (empty if no extend).

interfaceClass

public JavaClass interfaceClass(String name)
Provides the instance of the class element named name.

Parameters:
name - the name of the class to find.
Returns:
the associated Java model element (null if not found).

parameters

public String parameters(JavaClass cls)
Provides the list of parameters of a component.

Overrides:
parameters in class PrimitiveDefinitionPlugin
Parameters:
cls - the component considered.
Returns:
the parameters of the component.