element persistence

element {http://java.sun.com/xml/ns/persistence}persistence

Abstractfalse (This can be used in an instance)
Nillablefalse (Instance values cannot use xsi:nil)
Target Namespacehttp://java.sun.com/xml/ns/persistence
Declared Namespacesxmlns:xsd=http://www.w3.org/2001/XMLSchema
xmlns:persistence=http://java.sun.com/xml/ns/persistence


Source

<xsd:element name="persistence">
    <
xsd:complexType>
        <
xsd:sequence>
<!--
****************************************************-->
            <
xsd:element name="persistence-unit" minOccurs="0" maxOccurs="unbounded">
                <
xsd:complexType>
                    <
xsd:annotation>
                        <
xsd:documentation>Configuration of a persistence unit.</xsd:documentation>
                    </
xsd:annotation>
                    <
xsd:sequence>
<!--
****************************************************-->
                        <
xsd:element name="description" type="xsd:string" minOccurs="0">
                            <
xsd:annotation>
                                <
xsd:documentation>Textual description of this persistence unit.</xsd:documentation>
                            </
xsd:annotation>
                        </
xsd:element>
<!--
****************************************************-->
                        <
xsd:element name="provider" type="xsd:string" minOccurs="0">
                            <
xsd:annotation>
                                <
xsd:documentation>
Provider class that supplies EntityManagers for this
persistence unit.
                                
</xsd:documentation>
                            </
xsd:annotation>
                        </
xsd:element>
<!--
****************************************************-->
                        <
xsd:element name="jta-data-source" type="xsd:string" minOccurs="0">
                            <
xsd:annotation>
                                <
xsd:documentation>The container-specific name of the JTA datasource to use.</xsd:documentation>
                            </
xsd:annotation>
                        </
xsd:element>
<!--
****************************************************-->
                        <
xsd:element name="non-jta-data-source" type="xsd:string" minOccurs="0">
                            <
xsd:annotation>
                                <
xsd:documentation>The container-specific name of a non-JTA datasource to use.</xsd:documentation>
                            </
xsd:annotation>
                        </
xsd:element>
<!--
****************************************************-->
                        <
xsd:element name="mapping-file" type="xsd:string" minOccurs="0"
                            
maxOccurs="unbounded">
                            <
xsd:annotation>
                                <
xsd:documentation>
File containing mapping information. Loaded as a resource
by the persistence provider.
                                
</xsd:documentation>
                            </
xsd:annotation>
                        </
xsd:element>
<!--
****************************************************-->
                        <
xsd:element name="jar-file" type="xsd:string" minOccurs="0"
                            
maxOccurs="unbounded">
                            <
xsd:annotation>
                                <
xsd:documentation>
Jar file that should be scanned for entities.
Not applicable to Java SE persistence units.
                                
</xsd:documentation>
                            </
xsd:annotation>
                        </
xsd:element>
<!--
****************************************************-->
                        <
xsd:element name="class" type="xsd:string" minOccurs="0"
                            
maxOccurs="unbounded">
                            <
xsd:annotation>
                                <
xsd:documentation>
Class to scan for annotations. It should be annotated
with either @Entity, @Embeddable or @MappedSuperclass.
                                
</xsd:documentation>
                            </
xsd:annotation>
                        </
xsd:element>
<!--
****************************************************-->
                        <
xsd:element name="exclude-unlisted-classes" type="xsd:boolean"
                            
default="false" minOccurs="0">
                            <
xsd:annotation>
                                <
xsd:documentation>
When set to true then only listed classes and jars will
be scanned for persistent classes, otherwise the enclosing
jar or directory will also be scanned. Not applicable to
Java SE persistence units.
                                
</xsd:documentation>
                            </
xsd:annotation>
                        </
xsd:element>
<!--
****************************************************-->
                        <
xsd:element name="properties" minOccurs="0">
                            <
xsd:annotation>
                                <
xsd:documentation>A list of vendor-specific properties.</xsd:documentation>
                            </
xsd:annotation>
                            <
xsd:complexType>
                                <
xsd:sequence>
                                    <
xsd:element name="property" minOccurs="0" maxOccurs="unbounded">
                                        <
xsd:annotation>
                                            <
xsd:documentation>A name-value pair.</xsd:documentation>
                                        </
xsd:annotation>
                                        <
xsd:complexType>
                                            <
xsd:attribute name="name" type="xsd:string"
                                                
use="required"/>
                                            <
xsd:attribute name="value" type="xsd:string"
                                                
use="required"/>
                                        </
xsd:complexType>
                                    </
xsd:element>
                                </
xsd:sequence>
                            </
xsd:complexType>
                        </
xsd:element>
                    </
xsd:sequence>
<!--
****************************************************-->
                    <
xsd:attribute name="name" type="xsd:string" use="required">
                        <
xsd:annotation>
                            <
xsd:documentation>Name used in code to reference this persistence unit.</xsd:documentation>
                        </
xsd:annotation>
                    </
xsd:attribute>
<!--
****************************************************-->
                    <
xsd:attribute name="transaction-type"
                        
type="persistence:persistence-unit-transaction-type">
                        <
xsd:annotation>
                            <
xsd:documentation>
Type of transactions used by EntityManagers from this
persistence unit.
                            
</xsd:documentation>
                        </
xsd:annotation>
                    </
xsd:attribute>
                </
xsd:complexType>
            </
xsd:element>
        </
xsd:sequence>
        <
xsd:attribute name="version" type="persistence:versionType" fixed="1.0" use="required"/>
    </
xsd:complexType>
</
xsd:element>


element persistence


Stylus Studio XML Schema Library Home
Site Map | Privacy Policy | Terms of Use | Trademarks
Stylus Scoop XML Newsletter:
W3C Member
Stylus Studio®, a product from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2006 All Rights Reserved.