Update of /cvsroot/jaxme/JaxMe2/src/net/sf/jaxme/junit
In directory sc8-pr-cvs1:/tmp/cvs-serv14248/src/net/sf/jaxme/junit
Modified Files:
MarshallerTest.java
Log Message:
Added xs:hexBinary, xs:base64Binary, xs:positiveInteger and
xs:NMTOKEN. JUnit tests are partially missing or not working.
(Jochen Wiedmann)
Added example schema PurchaseOrder (Marty Kube).
Index: MarshallerTest.java
===================================================================
RCS file: /cvsroot/jaxme/JaxMe2/src/net/sf/jaxme/junit/MarshallerTest.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- MarshallerTest.java 9 Feb 2003 17:51:58 -0000 1.4
+++ MarshallerTest.java 10 Feb 2003 21:07:46 -0000 1.5
@@ -87,6 +87,9 @@
d.setSeconds(6.7);
return d;
}
+ public byte[] getHexBytes() {
+ return new byte[]{1, 17, 35, 78, 115, -99, -69, -1 };
+ }
public AllSimpleTypesElement getAllSimpleTypesElement() {
AllSimpleTypesElement element = new AllSimpleTypesElementImpl();
@@ -100,6 +103,7 @@
element.setDateTimeElem(getDateTime());
element.setTimeElem(getTime());
element.setDurationElem(getDuration());
+ element.setHexBinaryElem(getHexBytes());
return element;
}
@@ -128,6 +132,7 @@
"<ex:DateElem>" + DateFormat.getDateInstance().format(getDate().getTime()) +
"</ex:DateElem>" +
"<ex:TimeElem>" + DateFormat.getTimeInstance().format(getTime().getTime()) +
"</ex:TimeElem>" +
"<ex:DurationElem>P1Y2M3DT4H4M" + NumberFormat.getInstance().format(6.7) +
"S</ex:DurationElem>" +
+ "<ex:HexBinaryElem>0111234E739DBBFF</ex:HexBinaryElem>" +
"</ex:AllSimpleTypesElement>";
}
@@ -145,6 +150,7 @@
" <ex:DateElem>" + DateFormat.getDateInstance().format(getDate().getTime())
+ "</ex:DateElem>\n" +
" <ex:TimeElem>" + DateFormat.getTimeInstance().format(getTime().getTime())
+ "</ex:TimeElem>\n" +
" <ex:DurationElem>P1Y2M3DT4H4M" + NumberFormat.getInstance().format(6.7) +
"S</ex:DurationElem>\n" +
+ " <ex:HexBinaryElem>0111234E739DBBFF</ex:HexBinaryElem>\n" +
" </ex:AllSimpleTypesElement>\n" +
" <ex:ListTypeElement>7 -3 0</ex:ListTypeElement>\n" +
" <ex:UnionTypeElement>" +
DateFormat.getDateTimeInstance().format(getDateTime().getTime()) +
"</ex:UnionTypeElement>\n" +
@@ -180,6 +186,7 @@
String time2 =
DateFormat.getTimeInstance().format(pElement.getTimeElem().getTime());
assertEquals(time1, time2);
assertEquals(getDuration(), pElement.getDurationElem());
+ assertEquals(getHexBytes(), pElement.getHexBinaryElem());
}
public void verifyAllTypesElement(AllTypesElement pElement) {
-------------------------------------------------------
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
_______________________________________________
Jaxme-jaxb-dev mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jaxme-jaxb-dev