public class EntityFetchGroup extends FetchGroup
| Constructor and Description |
|---|
EntityFetchGroup(java.util.Collection<java.lang.String> attributeNames) |
EntityFetchGroup(FetchGroup fetchGroup) |
EntityFetchGroup(FetchGroup fetchGroup,
java.lang.String attributeName) |
EntityFetchGroup(java.lang.String attributeName) |
EntityFetchGroup(java.lang.String[] attributeNames) |
| Modifier and Type | Method and Description |
|---|---|
void |
addAttribute(java.lang.String attributeNameOrPath,
AttributeGroup group)
Add a basic attribute or nested attribute with each String representing
an attribute on the path to what needs to be included in the
AttributeGroup.
|
boolean |
isEntityFetchGroup() |
boolean |
isSupersetOf(AttributeGroup anotherGroup)
Return true if this EntityFetchGroup is a super-set of the passed in
EntityFetchGroup.
|
java.lang.String |
onUnfetchedAttribute(FetchGroupTracker entity,
java.lang.String attributeName)
Called on attempt to get value of an attribute that hasn't been fetched yet.
|
java.lang.String |
onUnfetchedAttributeForSet(FetchGroupTracker entity,
java.lang.String attributeName)
Called on attempt to assign value to an attribute that hasn't been fetched yet.
|
void |
removeAttribute(java.lang.String attributeNameOrPath)
Remove an attribute from the group.
|
void |
setOnEntity(java.lang.Object entity,
AbstractSession session)
Set this EntityFetchGroup on an entity implementing
FetchGroupTracker. |
addAttribute, addAttributeKey, clone, getAttributes, getEntityFetchGroup, getGroup, getRootEntity, isFetchGroup, setRootEntity, setShouldLoad, setShouldLoadAll, shouldLoad, toLoadGroup, toLoadGroupLoadOnlyaddAttribute, addAttributes, clone, containsAttribute, containsAttributeInternal, convertClassNamesToClasses, equals, findGroup, getAllItems, getAttributeNames, getItem, getItems, getName, getSubClassGroups, getType, getTypeName, hasInheritance, hasItems, insertSubClass, isConcurrent, isCopyGroup, isLoadGroup, setAllSubclasses, setAttributeNames, setName, toCopyGroup, toCopyGroup, toFetchGroup, toFetchGroup, toLoadGroup, toStringpublic EntityFetchGroup(FetchGroup fetchGroup)
public EntityFetchGroup(java.lang.String attributeName)
public EntityFetchGroup(java.util.Collection<java.lang.String> attributeNames)
public EntityFetchGroup(java.lang.String[] attributeNames)
public EntityFetchGroup(FetchGroup fetchGroup, java.lang.String attributeName)
public void addAttribute(java.lang.String attributeNameOrPath,
AttributeGroup group)
AttributeGroup
Example:
group.addAttribute("firstName", group1);
Note that existing group corresponding to attributeNameOrPath
will be overridden with the passed group.
group.addAttribute("manager.address", group2);
addAttribute in class FetchGroupgroup - - an AttributeGroup to be added.public java.lang.String onUnfetchedAttribute(FetchGroupTracker entity, java.lang.String attributeName)
onUnfetchedAttribute in class FetchGrouppublic java.lang.String onUnfetchedAttributeForSet(FetchGroupTracker entity, java.lang.String attributeName)
onUnfetchedAttributeForSet in class FetchGrouppublic void removeAttribute(java.lang.String attributeNameOrPath)
AttributeGroupremoveAttribute in class AttributeGrouppublic void setOnEntity(java.lang.Object entity,
AbstractSession session)
FetchGroupTracker.public boolean isEntityFetchGroup()
isEntityFetchGroup in class FetchGrouppublic boolean isSupersetOf(AttributeGroup anotherGroup)
isSupersetOf in class AttributeGroupEclipseLink 2.4.2, "build v20130514-5956486" API Reference