You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jdo-commits@db.apache.org by mb...@apache.org on 2020/07/18 19:57:59 UTC
[db-jdo] 01/02: JDO-783: Add missing jdoconfig 3.2 DTD and XSD
This is an automated email from the ASF dual-hosted git repository.
mbo pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/db-jdo.git
commit 7955c6a3d6dac0a1aec9deb97ab0fd026a44ab12
Author: Michael Bouschen <mb...@apache.org>
AuthorDate: Sat Jul 18 21:57:19 2020 +0200
JDO-783: Add missing jdoconfig 3.2 DTD and XSD
---
api/src/main/resources/javax/jdo/jdoconfig_3_2.dtd | 55 +++++++
api/src/main/resources/javax/jdo/jdoconfig_3_2.xsd | 178 +++++++++++++++++++++
2 files changed, 233 insertions(+)
diff --git a/api/src/main/resources/javax/jdo/jdoconfig_3_2.dtd b/api/src/main/resources/javax/jdo/jdoconfig_3_2.dtd
new file mode 100644
index 0000000..4ae002a
--- /dev/null
+++ b/api/src/main/resources/javax/jdo/jdoconfig_3_2.dtd
@@ -0,0 +1,55 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<!--
+<!DOCTYPE jdoconfig
+ PUBLIC "-//Sun Microsystems, Inc.//DTD Java Data Objects Configuration 3.2//EN"
+ "http://xmlns.jcp.org/dtd/jdoconfig_3_2.dtd">
+-->
+<!ELEMENT jdoconfig (persistence-manager-factory+)>
+
+<!ELEMENT persistence-manager-factory (property*, instance-lifecycle-listener*)>
+<!ATTLIST persistence-manager-factory class CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory name CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory persistence-unit-name CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory optimistic (true|false) CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory readonly (true|false) CDATA 'false'>
+<!ATTLIST persistence-manager-factory retain-values (true|false) CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory restore-values (true|false) CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory ignore-cache (true|false) CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory nontransactional-read (true|false) CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory nontransactional-write (true|false) CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory multithreaded (true|false) CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory transaction-isolation-level CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory connection-driver-name CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory connection-user-name CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory connection-password CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory connection-url CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory connection-factory-name CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory connection-factory2-name CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory mapping CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory detach-all-on-commit (true|false) CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory server-time-zone-id CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory datastore-read-timeout-millis CDATA #IMPLIED>
+<!ATTLIST persistence-manager-factory datastore-write-timeout-millis CDATA #IMPLIED>
+
+<!ELEMENT property EMPTY>
+<!ATTLIST property name CDATA #REQUIRED>
+<!ATTLIST property value CDATA #IMPLIED>
+
+<!ELEMENT instance-lifecycle-listener EMPTY>
+<!ATTLIST instance-lifecycle-listener listener CDATA #REQUIRED>
+<!ATTLIST instance-lifecycle-listener classes CDATA #IMPLIED>
diff --git a/api/src/main/resources/javax/jdo/jdoconfig_3_2.xsd b/api/src/main/resources/javax/jdo/jdoconfig_3_2.xsd
new file mode 100644
index 0000000..9d468fa
--- /dev/null
+++ b/api/src/main/resources/javax/jdo/jdoconfig_3_2.xsd
@@ -0,0 +1,178 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<xs:schema
+ targetNamespace="http://xmlns.jcp.org/xml/ns/jdo/jdoconfig"
+ xmlns="http://xmlns.jcp.org/xml/ns/jdo/jdoconfig"
+ xmlns:xs="http://www.w3.org/2001/XMLSchema"
+ xmlns:jdoconfig="http://xmlns.jcp.org/xml/ns/jdo/jdoconfig"
+ elementFormDefault="qualified"
+ attributeFormDefault="unqualified"
+ version="3.2">
+ <xs:annotation>
+ <xs:documentation>
+ This is the XML Schema for the JDO configuration file.
+ </xs:documentation>
+ </xs:annotation>
+
+ <xs:element name="jdoconfig">
+ <xs:complexType>
+ <xs:annotation>
+ <xs:documentation>
+ The root configuration element for JDO.
+ </xs:documentation>
+ </xs:annotation>
+ <xs:sequence>
+ <xs:element name="persistence-manager-factory" minOccurs="1"
+ maxOccurs="unbounded">
+ <xs:complexType>
+ <xs:annotation>
+ <xs:documentation>
+ Standard JDO PersistenceManagerFactory configuration properties.
+ Vendor-specific properties are set using additional
+ vendor-specific attributes and/or property elements.
+ </xs:documentation>
+ </xs:annotation>
+ <xs:sequence minOccurs="0" maxOccurs="1">
+ <xs:element name="property" minOccurs="0"
+ maxOccurs="unbounded">
+ <xs:complexType>
+ <xs:annotation>
+ <xs:documentation>
+ Vendor-specific properties.
+ </xs:documentation>
+ </xs:annotation>
+ <xs:attributeGroup ref="attlist.property"/>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="instance-lifecycle-listener"
+ minOccurs="0" maxOccurs="unbounded">
+ <xs:complexType>
+ <xs:annotation>
+ <xs:documentation>
+ javax.jdo.listener.InstanceLifecycleListener instance
+ configuration. There is one instance-lifecycle-listener
+ element per listener instance. Only one instance of the
+ listener class is supported in this configuration file.
+ If multiple instances of the same listener class is
+ required, then the API
+ PersistenceManagerFactory.addInstanceLifecycleListener(...)
+ must be used.
+
+ If attribute "classes" is missing, all persistence-capable
+ instances are observed; otherwise it is a comma- or
+ whitespace-delimited list of persistence-capable
+ classes whose instances will be observed.
+ </xs:documentation>
+ </xs:annotation>
+ <xs:attributeGroup
+ ref="attlist.instance-lifecycle-listener"/>
+ </xs:complexType>
+ </xs:element>
+ </xs:sequence>
+ <xs:attributeGroup
+ ref="attlist.persistence-manager-factory"/>
+ </xs:complexType>
+ </xs:element>
+ </xs:sequence>
+ <xs:attributeGroup ref="attlist.jdoconfig"/>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:attributeGroup name="attlist.jdoconfig"/>
+
+ <xs:attributeGroup name="attlist.persistence-manager-factory">
+ <xs:annotation>
+ <xs:documentation>
+ These are attributes corresponding to the standard properties
+ defined in JDO.
+ Any other attributes present, if unrecognized by a JDO
+ implementation, may be silently ignored.
+ </xs:documentation>
+ </xs:annotation>
+
+ <!-- Corresponds to standard JDO property javax.jdo.PersistenceManagerFactoryClass. -->
+ <xs:attribute name="class" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.Name.
+ The absence of this attribute implies the anonymous PMF. -->
+ <xs:attribute name="name" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.PersistenceUnitName. -->
+ <xs:attribute name="persistence-unit-name" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.Optimistic. -->
+ <xs:attribute name="optimistic" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.ReadOnly. -->
+ <xs:attribute name="readonly" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.RetainValues. -->
+ <xs:attribute name="retain-values" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.RestoreValues. -->
+ <xs:attribute name="restore-values" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.IgnoreCache. -->
+ <xs:attribute name="ignore-cache" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.NontransactionalRead. -->
+ <xs:attribute name="nontransactional-read" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.NontransactionalWrite. -->
+ <xs:attribute name="nontransactional-write" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.Multithreaded. -->
+ <xs:attribute name="multithreaded" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.TransactionIsolationLevel. -->
+ <xs:attribute name="transaction-isolation-level" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.ConnectionDriverName. -->
+ <xs:attribute name="connection-driver-name" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.ConnectionUserName. -->
+ <xs:attribute name="connection-user-name" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.ConnectionPassword. -->
+ <xs:attribute name="connection-password" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.ConnectionURL. -->
+ <xs:attribute name="connection-url" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.ConnectionFactoryName. -->
+ <xs:attribute name="connection-factory-name" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.ConnectionFactory2Name. -->
+ <xs:attribute name="connection-factory2-name" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.Mapping. -->
+ <xs:attribute name="mapping" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.DetachAllOnCommit. -->
+ <xs:attribute name="detach-all-on-commit" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.ServerTimeZoneID. -->
+ <xs:attribute name="server-time-zone-id" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.DatastoreReadTimeoutMillis. -->
+ <xs:attribute name="datastore-read-timeout-millis" use="optional"/>
+ <!-- Corresponds to standard JDO property javax.jdo.option.DatastoreWriteTimeoutMillis. -->
+ <xs:attribute name="datastore-write-timeout-millis" use="optional"/>
+ <!-- Any other vendor-specific attributes are allowed and passed literally
+ to the underlying implementation. -->
+ <xs:anyAttribute processContents="lax"/>
+ </xs:attributeGroup>
+
+ <xs:attributeGroup name="attlist.property">
+ <!-- The name of the vendor-specific property. -->
+ <xs:attribute name="name" use="required"/>
+ <!-- The value of the vendor-specific property. -->
+ <xs:attribute name="value" use="optional"/>
+ </xs:attributeGroup>
+
+ <xs:attributeGroup name="attlist.instance-lifecycle-listener">
+ <!-- The name of the listener class to instantiate. -->
+ <xs:attribute name="listener" use="required"/>
+ <!-- Comma- or whitespace-delimited list of persistence-capable classes
+ whose instances to observe. The absence of this attribute means
+ to observe all. -->
+ <xs:attribute name="classes" use="optional"/>
+ </xs:attributeGroup>
+
+</xs:schema>
+