info.magnolia.templating.freemarker
Class RenderableDefinitionModel.Factory

java.lang.Object
  extended by info.magnolia.templating.freemarker.RenderableDefinitionModel.Factory
All Implemented Interfaces:
freemarker.ext.util.ModelFactory, MagnoliaModelFactory
Enclosing class:
RenderableDefinitionModel

public static final class RenderableDefinitionModel.Factory
extends Object
implements MagnoliaModelFactory

A factory for the enclosing type.


Constructor Summary
RenderableDefinitionModel.Factory()
           
 
Method Summary
 freemarker.template.TemplateModel create(Object object, freemarker.template.ObjectWrapper wrapper)
          If possible, our models should instantiate models which implement AdapterTemplateModel, so they can be unwrapped easily.
 Class factoryFor()
          Returns the Class this ModelFactory is able to create Model instances for.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RenderableDefinitionModel.Factory

public RenderableDefinitionModel.Factory()
Method Detail

factoryFor

public Class factoryFor()
Description copied from interface: MagnoliaModelFactory
Returns the Class this ModelFactory is able to create Model instances for. MagnoliaObjectWrapper uses this with a isAssignableFrom call to determine which ModelFactory to use.

Specified by:
factoryFor in interface MagnoliaModelFactory

create

public freemarker.template.TemplateModel create(Object object,
                                                freemarker.template.ObjectWrapper wrapper)
Description copied from interface: MagnoliaModelFactory
If possible, our models should instantiate models which implement AdapterTemplateModel, so they can be unwrapped easily. (by custom directives, for example)

Specified by:
create in interface freemarker.ext.util.ModelFactory
Specified by:
create in interface MagnoliaModelFactory
See Also:
AdapterTemplateModel


Copyright © 2003-2012 Magnolia International Ltd.. All Rights Reserved.