net.sf.qualitytest.blueprint
Class BlueprintSession

java.lang.Object
  extended by net.sf.qualitytest.blueprint.BlueprintSession

@NotThreadSafe
public final class BlueprintSession
extends Object

A BlueprintSession holds information acquired while doing a blueprint of a class. This includes cycle detection as well as statistical information.

Author:
Dominik Seichter

Constructor Summary
BlueprintSession()
           
 
Method Summary
 Set<Class<?>> getBlueprintClasses()
          Retrieve all classes that have been blueprinted in the current session.
 int getBlueprintCount()
          Retrieve the number of objects which have been blueprinted in the current session.
 void pop()
          Call after creating a blueprint of a class.
 void push(Class<?> clazz)
          Call before creating a blueprint of a class.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BlueprintSession

public BlueprintSession()
Method Detail

getBlueprintClasses

public Set<Class<?>> getBlueprintClasses()
Retrieve all classes that have been blueprinted in the current session.

Returns:
a set of classes encountered while creating the blueprint

getBlueprintCount

public int getBlueprintCount()
Retrieve the number of objects which have been blueprinted in the current session.

Returns:
number of objects that have been blueprinted in the current session

pop

public void pop()
Call after creating a blueprint of a class.


push

public void push(@Nonnull
                 Class<?> clazz)
Call before creating a blueprint of a class. The internal stack is used to do cycle detection in the blueprinting graph.

Parameters:
clazz - the class for which a blueprint is created
Throws:
{@code - BlueprintCycleException} if a cycle has been detected


Copyright © 2012-2013. All Rights Reserved.