blob: dbf5802dd968ffcb53eb9da210875c847e4597ac [file] [log] [blame]
<?xml version="1.0" encoding="US-ASCII"?>
<!--
Copyright (c) 2018, 2020 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0 which is available at
http://www.eclipse.org/legal/epl-2.0,
or the Eclipse Distribution License v. 1.0 which is available at
http://www.eclipse.org/org/documents/edl-v10.php.
SPDX-License-Identifier: EPL-2.0 OR BSD-3-Clause
-->
<xml-bindings xmlns="http://www.eclipse.org/eclipselink/xsds/persistence/oxm" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xml-schema namespace="http://www.example.com/employees">
<xml-ns namespace-uri="http://www.example.com/projects" prefix="prj"/>
</xml-schema>
<java-types>
<java-type name="org.eclipse.persistence.testing.jaxb.annotations.xmlnullpolicy.EmployeeNoXmlElement">
<xml-root-element name="employee" />
<java-attributes>
<xml-attribute java-attribute="empId" name="id" />
<xml-attribute java-attribute="salary" read-only="true" />
<xml-attribute java-attribute="mgrId" xml-path="projects/prj:project/@prj:managerId" />
<xml-element java-attribute="firstName" xml-path="info/personal-info/first-name/text()" />
<xml-element java-attribute="lastName" xml-path="info/personal-info/last-name/text()" />
<xml-element java-attribute="projectName" xml-path="projects/prj:project/name/text()">
<xml-access-methods get-method="getProject" set-method="setProject" />
</xml-element>
<xml-element java-attribute="data2" xml-path="pieces-of-data/data[2]/text()" />
<xml-element java-attribute="data1" xml-path="pieces-of-data/data[1]/text()" />
<xml-element java-attribute="privateData" name="private-data" write-only="true" />
<xml-element java-attribute="characterData" name="character-data" cdata="true" />
<xml-element java-attribute="projectId" name="project-id" default-value="999" />
</java-attributes>
</java-type>
</java-types>
</xml-bindings>