org.objectweb.fractal.juliak.asm
Interface ClassGenerator

All Known Implementing Classes:
AbstractClassGenerator, CloneableAttributeControllerClassGenerator, InterceptorClassGenerator, InterfaceClassGenerator

public interface ClassGenerator

Root class for InterfaceType-based class generators.

Since:
2.5
Author:
Lionel Seinturier

Method Summary
 Class generate(InterfaceType it, InitializationContext ic)
          Generate a class implementing the given Fractal interface type.
 byte[] generate(String targetClassname, InterfaceType it, InitializationContext ic)
          Generate the bytecode of a class implementing the given Fractal interface type.
 String getTargetClassName(InterfaceType it)
          Return the name of the class generated by the current class generator for the specified interface type.
 boolean match(InterfaceType it)
          Return true if the mode (IN, OUT or IN_OUT) of the class generator matchs the mode (client or server) of the given interface type.
 

Method Detail

match

boolean match(InterfaceType it)
Return true if the mode (IN, OUT or IN_OUT) of the class generator matchs the mode (client or server) of the given interface type.


generate

byte[] generate(String targetClassname,
                InterfaceType it,
                InitializationContext ic)
                throws InstantiationException
Generate the bytecode of a class implementing the given Fractal interface type.

Parameters:
targetClassname - the name of the class to generate
it - the corresponding interface type
ic - the context for initializing the generated class
Returns:
the bytecode of the generated class
Throws:
InstantiationException

generate

Class generate(InterfaceType it,
               InitializationContext ic)
               throws InstantiationException
Generate a class implementing the given Fractal interface type.

Parameters:
it - the interface type
ic - the context for initializing the generated class
Returns:
a class implementing the given Fractal interface type
Throws:
InstantiationException

getTargetClassName

String getTargetClassName(InterfaceType it)
Return the name of the class generated by the current class generator for the specified interface type.