import {JSONDigester} from "./JSONDigester"; /** *

Interface for use with {@link FactoryCreateRule}. * The rule calls {@link #createObject} to create an object * to be pushed onto the Digester stack * whenever it is matched.

* *

{@link AbstractObjectCreationFactory} is an abstract * implementation suitable for creating anonymous * ObjectCreationFactory implementations. */ export interface ObjectCreationFactory { /** *

Factory method called by {@link FactoryCreateRule} to supply an * object based on the element's attributes. * * @param attributes the element's attributes * * @throws Exception any exception thrown will be propagated upwards */ createObject(attributes:{[key:string]: any}):any; /** *

Returns the {@link Digester} that was set by the * {@link FactoryCreateRule} upon initialization. */ getDigester():JSONDigester; /** *

Set the {@link Digester} to allow the implementation to do logging, * classloading based on the digester's classloader, etc. * * @param digester parent Digester object */ setDigester(digester:JSONDigester):void; }