Package io.ebean.bean
Class NodeUsageCollector
java.lang.Object
io.ebean.bean.NodeUsageCollector
public final class NodeUsageCollector extends Object
Collects profile information for a bean (or reference/proxy bean) at a given node.
The node identifies the location of the bean in the object graph.
It has to use a weak reference so as to ensure that it does not stop the associated bean from being garbage collected.
-
Constructor Summary
Constructors Constructor Description NodeUsageCollector(ObjectGraphNode node, WeakReference<NodeUsageListener> managerRef) -
Method Summary
Modifier and Type Method Description voidaddUsed(String property)Add the name of a property that has been used.StringgetLoadProperty()ObjectGraphNodegetNode()Return the associated node which identifies the location in the object graph of the bean/reference.Set<String>getUsed()Return the set of used properties.booleanisEmpty()Return true if no properties where used.booleanisModified()Return true if the bean was modified by a setter.voidsetLoadProperty(String loadProperty)The property that invoked a lazy load.voidsetModified()The bean has been modified by a setter method.StringtoString()
-
Constructor Details
-
NodeUsageCollector
-
-
Method Details
-
setModified
The bean has been modified by a setter method. -
addUsed
Add the name of a property that has been used. -
setLoadProperty
The property that invoked a lazy load. -
getNode
Return the associated node which identifies the location in the object graph of the bean/reference. -
isEmpty
Return true if no properties where used. -
getUsed
Return the set of used properties. -
isModified
Return true if the bean was modified by a setter. -
getLoadProperty
-
toString
-