TEST testCase0001 - XmlAccessorType
DESCRIPTION
Jakarta XML Binding specification assertion: JAXB:SPEC:J2S:1044
Mapping: @XmlAccessorType annotation allows control over default serialization of fields and properties.
XmlAccessorType(AccessType.PUBLIC_MEMBER) By Default
The annotation XmlAccessorType on a package applies to all classes in the package.
The following inheritance semantics apply:
If there is a XmlAccessorType on a class, then it is used.
Otherwise, if a XmlAccessorType exists on one of its super classes, then it is inherited.
Otherwise, the XmlAccessorType on a package is inherited.
Note: Positive test. Xml consists of all required fileds without extra fields or properties.
FILES
Item | Value |
title |
testCase0001 - XmlAccessorType |
name |
testCase0001 |
source |
srcInherit1.java srcInherit1/package-info.java posField1.xml |
executeClass |
javasoft.sqe.tests.api.jakarta.xml.bind.J2XRuntimeTest |
keywords |
runtime positive jaxb rtgen |
executeArgs |
-out $testWorkDir -class javasoft.sqe.tests.java2schema.CustomizedMapping.packages.XmlAccessorType.srcInherit1.src -j srcInherit1.java:srcInherit1/package-info.java -d posField1.xml -TestURL $testURL |
TEST testCase0002 - XmlAccessorType
DESCRIPTION
Jakarta XML Binding specification assertion: JAXB:SPEC:J2S:1044
Mapping: @XmlAccessorType annotation allows control over default serialization of fields and properties.
XmlAccessorType(AccessType.PUBLIC_MEMBER) By Default
The annotation XmlAccessorType on a package applies to all classes in the package.
The following inheritance semantics apply:
If there is a XmlAccessorType on a class, then it is used.
Otherwise, if a XmlAccessorType exists on one of its super classes, then it is inherited.
Otherwise, the XmlAccessorType on a package is inherited.
Note: Negative test. Required field is absent in xml file.
FILES
Item | Value |
title |
testCase0002 - XmlAccessorType |
name |
testCase0002 |
source |
srcInherit1.java srcInherit1/package-info.java negField1.xml |
executeClass |
javasoft.sqe.tests.api.jakarta.xml.bind.J2XRuntimeTest |
keywords |
runtime positive jaxb rtgen |
executeArgs |
-out $testWorkDir -class javasoft.sqe.tests.java2schema.CustomizedMapping.packages.XmlAccessorType.srcInherit1.src -j srcInherit1.java:srcInherit1/package-info.java -n -d negField1.xml -TestURL $testURL |
TEST testCase0003 - XmlAccessorType
DESCRIPTION
Jakarta XML Binding specification assertion: JAXB:SPEC:J2S:1044
Mapping: @XmlAccessorType annotation allows control over default serialization of fields and properties.
XmlAccessorType(AccessType.PUBLIC_MEMBER) By Default
The annotation XmlAccessorType on a package applies to all classes in the package.
The following inheritance semantics apply:
If there is a XmlAccessorType on a class, then it is used.
Otherwise, if a XmlAccessorType exists on one of its super classes, then it is inherited.
Otherwise, the XmlAccessorType on a package is inherited.
Note: Negative test. Xml file contains extraneous property.
FILES
Item | Value |
title |
testCase0003 - XmlAccessorType |
name |
testCase0003 |
source |
srcInherit1.java srcInherit1/package-info.java negField2.xml |
executeClass |
javasoft.sqe.tests.api.jakarta.xml.bind.J2XRuntimeTest |
keywords |
runtime positive jaxb rtgen |
executeArgs |
-out $testWorkDir -class javasoft.sqe.tests.java2schema.CustomizedMapping.packages.XmlAccessorType.srcInherit1.src -j srcInherit1.java:srcInherit1/package-info.java -n -d negField2.xml -TestURL $testURL |
TEST testCase0004 - XmlAccessorType
DESCRIPTION
Jakarta XML Binding specification assertion: JAXB:SPEC:J2S:1044
Mapping: @XmlAccessorType annotation allows control over default serialization of fields and properties.
XmlAccessorType(AccessType.PUBLIC_MEMBER) By Default
The annotation XmlAccessorType on a package applies to all classes in the package.
The following inheritance semantics apply:
If there is a XmlAccessorType on a class, then it is used.
Otherwise, if a XmlAccessorType exists on one of its super classes, then it is inherited.
Otherwise, the XmlAccessorType on a package is inherited.
Note: Negative test. Xml file contains extraneous field (transient field in java file)
FILES
Item | Value |
title |
testCase0004 - XmlAccessorType |
name |
testCase0004 |
source |
srcInherit1.java srcInherit1/package-info.java negField3.xml |
executeClass |
javasoft.sqe.tests.api.jakarta.xml.bind.J2XRuntimeTest |
keywords |
runtime positive jaxb rtgen |
executeArgs |
-out $testWorkDir -class javasoft.sqe.tests.java2schema.CustomizedMapping.packages.XmlAccessorType.srcInherit1.src -j srcInherit1.java:srcInherit1/package-info.java -n -d negField3.xml -TestURL $testURL |
%Copyright% © 2017, 2020 Oracle and/or its affiliates. All rights reserved.