org.apache.openejb.jee
Class PersistenceContextRef

java.lang.Object
  extended by org.apache.openejb.jee.PersistenceContextRef
All Implemented Interfaces:
Injectable, JndiReference, Keyable<String>, PersistenceRef

public class PersistenceContextRef
extends Object
implements JndiReference, PersistenceRef

javaee6.xsd

Java class for persistence-context-refType complex type.

The following schema fragment specifies the expected content contained within this class.

 <complexType name="persistence-context-refType">
   <complexContent>
     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
       <sequence>
         <element name="description" type="{http://java.sun.com/xml/ns/javaee}descriptionType" maxOccurs="unbounded" minOccurs="0"/>
         <element name="persistence-context-ref-name" type="{http://java.sun.com/xml/ns/javaee}jndi-nameType"/>
         <element name="persistence-unit-name" type="{http://java.sun.com/xml/ns/javaee}string" minOccurs="0"/>
         <element name="persistence-context-type" type="{http://java.sun.com/xml/ns/javaee}persistence-context-typeType" minOccurs="0"/>
         <element name="persistence-property" type="{http://java.sun.com/xml/ns/javaee}propertyType" maxOccurs="unbounded" minOccurs="0"/>
         <group ref="{http://java.sun.com/xml/ns/javaee}resourceBaseGroup"/>
       </sequence>
       <attribute name="id" type="{http://www.w3.org/2001/XMLSchema}ID" />
     </restriction>
   </complexContent>
 </complexType>
 


Field Summary
protected  TextMap description
           
protected  String id
           
protected  Set<InjectionTarget> injectionTarget
           
protected  String lookupName
           
protected  String mappedName
           
protected  String persistenceContextRefName
           
protected  PersistenceContextType persistenceContextType
           
protected  List<Property> persistenceProperty
           
protected  String persistenceUnitName
           
 
Constructor Summary
PersistenceContextRef()
           
PersistenceContextRef(String persistenceContextRefName, String persistenceUnitName)
           
PersistenceContextRef(String persistenceContextRefName, String persistenceUnitName, PersistenceContextType persistenceContextType, List<Property> persistenceProperty)
           
 
Method Summary
 String getDescription()
           
 Text[] getDescriptions()
           
 String getId()
           
 Set<InjectionTarget> getInjectionTarget()
           
 String getKey()
          Gets the immutable key for this object.
 String getLookupName()
           
 String getMappedName()
           
 String getName()
           
 String getPersistenceContextRefName()
           
 PersistenceContextType getPersistenceContextType()
           
 List<Property> getPersistenceProperty()
           
 String getPersistenceUnitName()
           
 String getType()
           
 PersistenceContextRef injectionTarget(Class<?> clazz, String property)
           
 PersistenceContextRef injectionTarget(String className, String property)
           
 PersistenceContextRef lookup(String lookupName)
           
 PersistenceContextRef mappedName(String mappedName)
           
 PersistenceContextRef name(String persistenceContextRefName)
           
 PersistenceContextRef property(String name, String value)
           
 void setDescriptions(Text[] text)
           
 void setId(String value)
           
 void setLookupName(String lookupName)
           
 void setMappedName(String value)
           
 void setName(String name)
           
 void setPersistenceContextRefName(String value)
           
 void setPersistenceContextType(PersistenceContextType value)
           
 void setPersistenceProperty(List<Property> persistenceProperty)
           
 void setPersistenceUnitName(String value)
           
 void setType(String type)
           
 String toString()
           
 PersistenceContextRef type(PersistenceContextType persistenceContextType)
           
 PersistenceContextRef unit(String persistenceUnit)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

description

protected TextMap description

persistenceContextRefName

protected String persistenceContextRefName

persistenceUnitName

protected String persistenceUnitName

persistenceContextType

protected PersistenceContextType persistenceContextType

persistenceProperty

protected List<Property> persistenceProperty

mappedName

protected String mappedName

lookupName

protected String lookupName

injectionTarget

protected Set<InjectionTarget> injectionTarget

id

protected String id
Constructor Detail

PersistenceContextRef

public PersistenceContextRef()

PersistenceContextRef

public PersistenceContextRef(String persistenceContextRefName,
                             String persistenceUnitName)

PersistenceContextRef

public PersistenceContextRef(String persistenceContextRefName,
                             String persistenceUnitName,
                             PersistenceContextType persistenceContextType,
                             List<Property> persistenceProperty)
Method Detail

name

public PersistenceContextRef name(String persistenceContextRefName)

unit

public PersistenceContextRef unit(String persistenceUnit)

type

public PersistenceContextRef type(PersistenceContextType persistenceContextType)

mappedName

public PersistenceContextRef mappedName(String mappedName)

lookup

public PersistenceContextRef lookup(String lookupName)

injectionTarget

public PersistenceContextRef injectionTarget(String className,
                                             String property)

injectionTarget

public PersistenceContextRef injectionTarget(Class<?> clazz,
                                             String property)

property

public PersistenceContextRef property(String name,
                                      String value)

getName

public String getName()
Specified by:
getName in interface JndiReference

getKey

public String getKey()
Description copied from interface: Keyable
Gets the immutable key for this object.

Specified by:
getKey in interface Keyable<String>
Returns:
gets the immutable key for this object

getType

public String getType()
Specified by:
getType in interface JndiReference

setName

public void setName(String name)
Specified by:
setName in interface JndiReference

setType

public void setType(String type)
Specified by:
setType in interface JndiReference

getDescriptions

public Text[] getDescriptions()

setDescriptions

public void setDescriptions(Text[] text)

getDescription

public String getDescription()

getPersistenceContextRefName

public String getPersistenceContextRefName()

setPersistenceContextRefName

public void setPersistenceContextRefName(String value)

getPersistenceUnitName

public String getPersistenceUnitName()
Specified by:
getPersistenceUnitName in interface PersistenceRef

setPersistenceUnitName

public void setPersistenceUnitName(String value)
Specified by:
setPersistenceUnitName in interface PersistenceRef

getPersistenceContextType

public PersistenceContextType getPersistenceContextType()

setPersistenceContextType

public void setPersistenceContextType(PersistenceContextType value)

getPersistenceProperty

public List<Property> getPersistenceProperty()

getMappedName

public String getMappedName()
Specified by:
getMappedName in interface JndiReference

setMappedName

public void setMappedName(String value)
Specified by:
setMappedName in interface JndiReference

getLookupName

public String getLookupName()
Specified by:
getLookupName in interface JndiReference

setLookupName

public void setLookupName(String lookupName)
Specified by:
setLookupName in interface JndiReference

getInjectionTarget

public Set<InjectionTarget> getInjectionTarget()
Specified by:
getInjectionTarget in interface Injectable

getId

public String getId()

setId

public void setId(String value)

setPersistenceProperty

public void setPersistenceProperty(List<Property> persistenceProperty)

toString

public String toString()
Overrides:
toString in class Object


Copyright © 1999-2012 The Apache Software Foundation. All Rights Reserved.