Package spoon.template


package spoon.template

This package defines a framework for well-typed pure-Java templates.

A template is a regular Java class that implements the Template interface and that contains some template parameters.

Related Documentation

  • Interface Summary
    Interface
    Description
    Template<T extends CtElement>
    A template code is simply a piece of code that uses a TemplateParameter's instance.
    This interface defines a typed template parameter.
  • Class Summary
    Class
    Description
    handles the well-formedness and helper methods of templates
    This class represents a template parameter that defines a void block statement directly expressed in Java (no returns).
    This class represents an expression template parameter expressed in Java.
    Inserts all the methods, fields, constructors, initialization blocks (if target is a class), inner types, and super interfaces (except Template) from a given template by substituting all the template parameters by their values.
    This class represents a template parameter that defines a statement list directly expressed in Java (no returns).
    This class defines the substitution API for templates (see Template).
    This class defines an engine for matching a template to pieces of code.
  • Exception Summary
    Exception
    Description
    This runtime exception can be throws when something wrong occurs in template operations such as loading, substitution, and matching.
  • Annotation Types Summary
    Annotation Type
    Description
    This annotation should be placed on templates' members to indicate that they are local elements of the template class.
    This annotation should be placed on templates' fields or methods to indicate that they represent template parameters.