Class PersistenceContextRefTypeImpl<T>
- java.lang.Object
-
- org.jboss.shrinkwrap.descriptor.impl.javaee6.PersistenceContextRefTypeImpl<T>
-
- All Implemented Interfaces:
org.jboss.shrinkwrap.descriptor.api.Child<T>,PersistenceContextRefType<T>
public class PersistenceContextRefTypeImpl<T> extends Object implements org.jboss.shrinkwrap.descriptor.api.Child<T>, PersistenceContextRefType<T>
This class implements thepersistence-context-refTypexsd type
-
-
Constructor Summary
Constructors Constructor Description PersistenceContextRefTypeImpl(T t, String nodeName, org.jboss.shrinkwrap.descriptor.spi.node.Node node)PersistenceContextRefTypeImpl(T t, String nodeName, org.jboss.shrinkwrap.descriptor.spi.node.Node node, org.jboss.shrinkwrap.descriptor.spi.node.Node childNode)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description InjectionTargetType<PersistenceContextRefType<T>>createInjectionTarget()Creates a newinjection-targetelementPropertyType<PersistenceContextRefType<T>>createPersistenceProperty()Creates a newpersistence-propertyelementPersistenceContextRefType<T>description(String... values)Creates for all String objects representingdescriptionelements, a newdescriptionelementList<String>getAllDescription()Returns alldescriptionelementsList<InjectionTargetType<PersistenceContextRefType<T>>>getAllInjectionTarget()Returns allinjection-targetelementsList<PropertyType<PersistenceContextRefType<T>>>getAllPersistenceProperty()Returns allpersistence-propertyelementsStringgetId()Returns theidattributeStringgetMappedName()Returns themapped-nameelementInjectionTargetType<PersistenceContextRefType<T>>getOrCreateInjectionTarget()If not already created, a newinjection-targetelement will be created and returned.PropertyType<PersistenceContextRefType<T>>getOrCreatePersistenceProperty()If not already created, a newpersistence-propertyelement will be created and returned.StringgetPersistenceContextRefName()Returns thepersistence-context-ref-nameelementPersistenceContextTypeTypegetPersistenceContextType()Returns thepersistence-context-typeelementStringgetPersistenceContextTypeAsString()Returns thepersistence-context-typeelementStringgetPersistenceUnitName()Returns thepersistence-unit-nameelementPersistenceContextRefType<T>id(String id)Sets theidattributePersistenceContextRefType<T>mappedName(String mappedName)Sets themapped-nameelementPersistenceContextRefType<T>persistenceContextRefName(String persistenceContextRefName)Sets thepersistence-context-ref-nameelementPersistenceContextRefType<T>persistenceContextType(String persistenceContextType)Sets thepersistence-context-typeelementPersistenceContextRefType<T>persistenceContextType(PersistenceContextTypeType persistenceContextType)Sets thepersistence-context-typeelementPersistenceContextRefType<T>persistenceUnitName(String persistenceUnitName)Sets thepersistence-unit-nameelementPersistenceContextRefType<T>removeAllDescription()Removes thedescriptionelementPersistenceContextRefType<T>removeAllInjectionTarget()Removes allinjection-targetelementsPersistenceContextRefType<T>removeAllPersistenceProperty()Removes allpersistence-propertyelementsPersistenceContextRefType<T>removeId()Removes theidattributePersistenceContextRefType<T>removeMappedName()Removes themapped-nameelementPersistenceContextRefType<T>removePersistenceContextRefName()Removes thepersistence-context-ref-nameelementPersistenceContextRefType<T>removePersistenceContextType()Removes thepersistence-context-typeattributePersistenceContextRefType<T>removePersistenceUnitName()Removes thepersistence-unit-nameelementTup()
-
-
-
Method Detail
-
mappedName
public PersistenceContextRefType<T> mappedName(String mappedName)
Sets themapped-nameelement- Specified by:
mappedNamein interfacePersistenceContextRefType<T>- Parameters:
mappedName- the value for the elementmapped-name- Returns:
- the current instance of
PersistenceContextRefType
-
getMappedName
public String getMappedName()
Returns themapped-nameelement- Specified by:
getMappedNamein interfacePersistenceContextRefType<T>- Returns:
- the node defined for the element
mapped-name
-
removeMappedName
public PersistenceContextRefType<T> removeMappedName()
Removes themapped-nameelement- Specified by:
removeMappedNamein interfacePersistenceContextRefType<T>- Returns:
- the current instance of
PersistenceContextRefType
-
getOrCreateInjectionTarget
public InjectionTargetType<PersistenceContextRefType<T>> getOrCreateInjectionTarget()
If not already created, a newinjection-targetelement will be created and returned. Otherwise, the first existinginjection-targetelement will be returned.- Specified by:
getOrCreateInjectionTargetin interfacePersistenceContextRefType<T>- Returns:
- the instance defined for the element
injection-target
-
createInjectionTarget
public InjectionTargetType<PersistenceContextRefType<T>> createInjectionTarget()
Creates a newinjection-targetelement- Specified by:
createInjectionTargetin interfacePersistenceContextRefType<T>- Returns:
- the new created instance of
InjectionTargetType>
-
getAllInjectionTarget
public List<InjectionTargetType<PersistenceContextRefType<T>>> getAllInjectionTarget()
Returns allinjection-targetelements- Specified by:
getAllInjectionTargetin interfacePersistenceContextRefType<T>- Returns:
- list of
injection-target
-
removeAllInjectionTarget
public PersistenceContextRefType<T> removeAllInjectionTarget()
Removes allinjection-targetelements- Specified by:
removeAllInjectionTargetin interfacePersistenceContextRefType<T>- Returns:
- the current instance of
InjectionTargetType>
-
description
public PersistenceContextRefType<T> description(String... values)
Creates for all String objects representingdescriptionelements, a newdescriptionelement- Specified by:
descriptionin interfacePersistenceContextRefType<T>- Parameters:
values- list ofdescriptionobjects- Returns:
- the current instance of
PersistenceContextRefType
-
getAllDescription
public List<String> getAllDescription()
Returns alldescriptionelements- Specified by:
getAllDescriptionin interfacePersistenceContextRefType<T>- Returns:
- list of
description
-
removeAllDescription
public PersistenceContextRefType<T> removeAllDescription()
Removes thedescriptionelement- Specified by:
removeAllDescriptionin interfacePersistenceContextRefType<T>- Returns:
- the current instance of
PersistenceContextRefType
-
persistenceContextRefName
public PersistenceContextRefType<T> persistenceContextRefName(String persistenceContextRefName)
Sets thepersistence-context-ref-nameelement- Specified by:
persistenceContextRefNamein interfacePersistenceContextRefType<T>- Parameters:
persistenceContextRefName- the value for the elementpersistence-context-ref-name- Returns:
- the current instance of
PersistenceContextRefType
-
getPersistenceContextRefName
public String getPersistenceContextRefName()
Returns thepersistence-context-ref-nameelement- Specified by:
getPersistenceContextRefNamein interfacePersistenceContextRefType<T>- Returns:
- the node defined for the element
persistence-context-ref-name
-
removePersistenceContextRefName
public PersistenceContextRefType<T> removePersistenceContextRefName()
Removes thepersistence-context-ref-nameelement- Specified by:
removePersistenceContextRefNamein interfacePersistenceContextRefType<T>- Returns:
- the current instance of
PersistenceContextRefType
-
persistenceUnitName
public PersistenceContextRefType<T> persistenceUnitName(String persistenceUnitName)
Sets thepersistence-unit-nameelement- Specified by:
persistenceUnitNamein interfacePersistenceContextRefType<T>- Parameters:
persistenceUnitName- the value for the elementpersistence-unit-name- Returns:
- the current instance of
PersistenceContextRefType
-
getPersistenceUnitName
public String getPersistenceUnitName()
Returns thepersistence-unit-nameelement- Specified by:
getPersistenceUnitNamein interfacePersistenceContextRefType<T>- Returns:
- the node defined for the element
persistence-unit-name
-
removePersistenceUnitName
public PersistenceContextRefType<T> removePersistenceUnitName()
Removes thepersistence-unit-nameelement- Specified by:
removePersistenceUnitNamein interfacePersistenceContextRefType<T>- Returns:
- the current instance of
PersistenceContextRefType
-
persistenceContextType
public PersistenceContextRefType<T> persistenceContextType(PersistenceContextTypeType persistenceContextType)
Sets thepersistence-context-typeelement- Specified by:
persistenceContextTypein interfacePersistenceContextRefType<T>- Parameters:
persistenceContextType- the value for the elementpersistence-context-type- Returns:
- the current instance of
PersistenceContextRefType
-
persistenceContextType
public PersistenceContextRefType<T> persistenceContextType(String persistenceContextType)
Sets thepersistence-context-typeelement- Specified by:
persistenceContextTypein interfacePersistenceContextRefType<T>- Parameters:
persistenceContextType- the value for the elementpersistence-context-type- Returns:
- the current instance of
PersistenceContextRefType
-
getPersistenceContextType
public PersistenceContextTypeType getPersistenceContextType()
Returns thepersistence-context-typeelement- Specified by:
getPersistenceContextTypein interfacePersistenceContextRefType<T>- Returns:
- the value found for the element
persistence-context-type
-
getPersistenceContextTypeAsString
public String getPersistenceContextTypeAsString()
Returns thepersistence-context-typeelement- Specified by:
getPersistenceContextTypeAsStringin interfacePersistenceContextRefType<T>- Returns:
- the value found for the element
persistence-context-type
-
removePersistenceContextType
public PersistenceContextRefType<T> removePersistenceContextType()
Removes thepersistence-context-typeattribute- Specified by:
removePersistenceContextTypein interfacePersistenceContextRefType<T>- Returns:
- the current instance of
PersistenceContextRefType
-
getOrCreatePersistenceProperty
public PropertyType<PersistenceContextRefType<T>> getOrCreatePersistenceProperty()
If not already created, a newpersistence-propertyelement will be created and returned. Otherwise, the first existingpersistence-propertyelement will be returned.- Specified by:
getOrCreatePersistencePropertyin interfacePersistenceContextRefType<T>- Returns:
- the instance defined for the element
persistence-property
-
createPersistenceProperty
public PropertyType<PersistenceContextRefType<T>> createPersistenceProperty()
Creates a newpersistence-propertyelement- Specified by:
createPersistencePropertyin interfacePersistenceContextRefType<T>- Returns:
- the new created instance of
PropertyType>
-
getAllPersistenceProperty
public List<PropertyType<PersistenceContextRefType<T>>> getAllPersistenceProperty()
Returns allpersistence-propertyelements- Specified by:
getAllPersistencePropertyin interfacePersistenceContextRefType<T>- Returns:
- list of
persistence-property
-
removeAllPersistenceProperty
public PersistenceContextRefType<T> removeAllPersistenceProperty()
Removes allpersistence-propertyelements- Specified by:
removeAllPersistencePropertyin interfacePersistenceContextRefType<T>- Returns:
- the current instance of
PropertyType>
-
id
public PersistenceContextRefType<T> id(String id)
Sets theidattribute- Specified by:
idin interfacePersistenceContextRefType<T>- Parameters:
id- the value for the attributeid- Returns:
- the current instance of
PersistenceContextRefType
-
getId
public String getId()
Returns theidattribute- Specified by:
getIdin interfacePersistenceContextRefType<T>- Returns:
- the value defined for the attribute
id
-
removeId
public PersistenceContextRefType<T> removeId()
Removes theidattribute- Specified by:
removeIdin interfacePersistenceContextRefType<T>- Returns:
- the current instance of
PersistenceContextRefType
-
-