Class DBWSModel

  • public class DBWSModel
    extends org.eclipse.persistence.internal.xr.XRServiceModel

    PUBLIC: model object for eclipselink-dbws.xml descriptor file. A DBWS (also known as an XRServiceAdapter) requires the following resources:

    • metadata in the form of a descriptor file called eclipselink-dbws.xml in the META-INF/ directory
      (inside a .jar file, as an external 'exploded' directory on the classpath
      or in the WEB-INF/classes/META-INF/ directory inside a .war file).
    • an XML Schema Definition (.xsd) file called eclipselink-dbws-schema.xsd
      located at the root directory of a .jar file, at the root of the first directory on the
      classpath or in the WEB-INF/wsdl/ directory of a .war file
    • an EclipseLink sessions.xml file called eclipselink-dbws-sessions.xml (in the META-INF/ directory)
        the naming convention for the sessions.xml files can be overridden by the
      optional <sessions-file> entry in the eclipselink-dbws.xml descriptor file.
    • EclipseLink metadata in the form of a EclipseLink Project (either deployment XML located
      in the META-INF/ directory or Java classes on the classpath or in the
      WEB-INF/classes directory inside a .war file).

      A typical DBWS requires two projects: one to represent the O-R side, the other to represent the O-X side.
      The O-R and O-X Projects metadata must have:
      i) identical case-sensitive Project names:

       <?xml version="1.0" encoding="UTF-8"?>
       <eclipselink:object-persistence version="Eclipse Persistence Services ..."
       import org.eclipse.persistence.sessions.Project;
       public class SomeORProject extends Project {
         public SomeORProject () {
       public class SomeOXProject extends Project {
         public SomeOXProject () {
      ii) identical case-sensitive aliases for Descriptors that are common between the projects:
       <eclipselink:class-mapping-descriptor xsi:type="eclipselink:relational-class-mapping-descriptor">
       <eclipselink:class-mapping-descriptor xsi:type="eclipselink:xml-class-mapping-descriptor">
    An example eclipselink-dbws.xml descriptor file:
     <?xml version="1.0" encoding="UTF-8"?>
         <sql><![CDATA[select count(*) from EMP]]></sql>
         <result isCollection="true">
         <sql><![CDATA[select * from EMP]]></sql>
    Mike Norman -
    EclipseLink 1.0
    • Field Summary

      • Fields inherited from class org.eclipse.persistence.internal.xr.XRServiceModel

        name, operations, sessionsFile
    • Constructor Summary

      Constructor Description
    • Method Summary

      • Methods inherited from class org.eclipse.persistence.internal.xr.XRServiceModel

        getName, getOperation, getOperations, getOperationsList, getSessionsFile, setName, setOperations, setSessionsFile
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • DBWSModel

        public DBWSModel()