org.sourceforge.jemm.lifecycle
Class ConstructorLifecycle

java.lang.Object
  extended by org.sourceforge.jemm.lifecycle.ConstructorLifecycle

public final class ConstructorLifecycle
extends java.lang.Object

A class with only static methods which enhanced objects can use to pass on events on object creation. Any attached listeners will receive begin and end events for the constructor.

Author:
Paul Keeble

Method Summary
static void addListener(ConstructorListener cl)
          Adds a new listener to the chain of called listeners.
static void beginConstructor(JEMMObject source)
          triggers the event for begin.
static void clearListeners()
          Removes any existing listeners.
static void endConstructor(JEMMObject source)
          Triggers the end event.
static void failedConstructor(JEMMObject source)
          Triggers the failed construction event.
static void preConstructor(java.lang.String clazz)
          triggers the event for begin.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

clearListeners

public static void clearListeners()
Removes any existing listeners.


addListener

public static void addListener(ConstructorListener cl)
Adds a new listener to the chain of called listeners.

Parameters:
cl -

preConstructor

public static void preConstructor(java.lang.String clazz)
triggers the event for begin.

Parameters:
source - The object from which the event is coming

beginConstructor

public static void beginConstructor(JEMMObject source)
triggers the event for begin.

Parameters:
source - The object from which the event is coming

endConstructor

public static void endConstructor(JEMMObject source)
Triggers the end event.

Parameters:
source - The object from which the event is coming

failedConstructor

public static void failedConstructor(JEMMObject source)
Triggers the failed construction event.

Parameters:
source - The object from which the event is coming


Copyright © 2009. All Rights Reserved.