home *** CD-ROM | disk | FTP | other *** search
- [
- '-----------------------------------------------------------
- ' Java XML Project Template
- '
- ' Copyright (C) 2002-2003 Altova GmbH - The XMLSPY Company
- ' All rights reserved.
- '
- ' XMLSPY 5 Enterprise Edition generates Java classes
- ' based on this template.
- ' Refer to the XMLSPY Documentation for further details.
- '
- ' http://www.altova.com/xmlspy
- '-----------------------------------------------------------
-
- map type "boolean" to "SchemaBoolean"
-
- map type "byte" to "SchemaByte"
- map type "unsignedByte" to "SchemaShort"
- map type "short" to "SchemaShort"
- map type "unsignedShort" to "SchemaInt"
- map type "int" to "SchemaInt"
- map type "unsignedInt" to "SchemaLong"
- map type "long" to "SchemaLong"
- map type "unsignedLong" to "SchemaInteger"
-
- map type "integer" to "SchemaInteger"
- map type "nonPositiveInteger" to "SchemaInteger"
- map type "negativeInteger" to "SchemaInteger"
- map type "positiveInteger" to "SchemaInteger"
- map type "nonNegativeInteger" to "SchemaInteger"
-
- map type "float" to "SchemaFloat"
- map type "double" to "SchemaDouble"
- map type "decimal" to "SchemaDecimal"
-
- map type "duration" to "SchemaString"
- map type "gYear" to "SchemaString"
- map type "gDay" to "SchemaString"
- map type "gMonth" to "SchemaString"
- map type "gYearMonth" to "SchemaString"
- map type "gMonthDay" to "SchemaString"
- map type "date" to "SchemaString"
- map type "time" to "SchemaString"
- map type "dateTime" to "SchemaDateTime"
-
- map type "anyURI" to "SchemaString"
- map type "QName" to "SchemaString"
- map type "NOTATION" to "SchemaString"
- map type "string" to "SchemaString"
- map type "normalizedString" to "SchemaNormalizedString"
- map type "token" to "SchemaToken"
- map type "language" to "SchemaLanguage"
- map type "Name" to "SchemaName"
- map type "NMTOKEN" to "SchemaNMToken"
- map type "NMTOKENS" to "SchemaNMToken"
- map type "NCName" to "SchemaNCName"
- map type "ID" to "SchemaID"
- map type "IDREF" to "SchemaIDRef"
- map type "IDREFS" to "SchemaIDRef"
- map type "ENTITY" to "SchemaEntity"
- map type "ENTITIES" to "SchemaEntity"
-
- map type "hexBinary" to "SchemaString"
- map type "base64Binary" to "SchemaString"
-
- map type "anySimpleType" to "SchemaString"
-
- default "ValidFirstCharSet" is "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz"
- default "ValidCharSet" is "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz_0123456789"
- default "InvalidCharReplacement" is "_"
- default "AnonTypePrefix" is ""
- default "AnonTypeSuffix" is "Type"
- default "ClassNamePrefix" is ""
- default "ClassNameSuffix" is ""
- default "FallbackName" is "Name"
-
- reserve "abstract"
- reserve "boolean"
- reserve "break"
- reserve "byte"
- reserve "case"
- reserve "catch"
- reserve "char"
- reserve "class"
- reserve "const"
- reserve "continue"
- reserve "default"
- reserve "do"
- reserve "double"
- reserve "else"
- reserve "extends"
- reserve "false"
- reserve "final"
- reserve "finally"
- reserve "float"
- reserve "for"
- reserve "goto"
- reserve "if"
- reserve "implements"
- reserve "import"
- reserve "instanceof"
- reserve "int"
- reserve "interface"
- reserve "long"
- reserve "native"
- reserve "new"
- reserve "null"
- reserve "package"
- reserve "private"
- reserve "protected"
- reserve "public"
- reserve "return"
- reserve "short"
- reserve "static"
- reserve "strictfp"
- reserve "super"
- reserve "switch"
- reserve "synchronized"
- reserve "this"
- reserve "throw"
- reserve "throws"
- reserve "transient"
- reserve "true"
- reserve "try"
- reserve "void"
- reserve "volatile"
- reserve "while"
-
- $JavaPackageName = "com.schema"
- $JavaPackageDir = "com/schema"
- $QualifiedBase = ""
- $QualifiedType = ""
- $QualifiedValueType = ""
- $BasePath = ""
- $IsQualified = ""
-
- '-----------------------------------------------------------
- ' Test Class
- '-----------------------------------------------------------
- $BasePath = $outputpath & "/" & $JavaPackageDir & "/"
- create $BasePath & $module & "Test.java" : include "java/ModuleTest.java" : close
- create $outputpath & "/Build" & $module & ".xml" : include "java/BuildModule.xml" : close
- create $outputpath & "/" & $module & ".jpx" : include "java/Module.jpx" : close
-
- '-----------------------------------------------------------
- ' Wrapper Library
- '-----------------------------------------------------------
- create $BasePath & $module & "Doc.java" : include "java/ModuleDoc.java" : close
- foreach $class in $classes
- $FullPackageDir = ""
- $FullPackageName = ""
-
- if $class.NamespacePrefix = ""
- $FullPackageDir = $JavaPackageDir
- $FullPackageName = $JavaPackageName
- else
- $FullPackageDir = $JavaPackageDir & "/" & $class.NamespacePrefix
- $FullPackageName = $JavaPackageName & "." & $class.NamespacePrefix
- endif
- if not $class.IsInternal
- create $outputpath & "/" & $FullPackageDir & "/" & $class.Name & ".java"
- include "java/Module.java"
- close
- endif
- next
-
- '-----------------------------------------------------------
- ' Altova XML Package
- '-----------------------------------------------------------
- $BasePath = $outputpath & "/com/altova/xml/"
- create $BasePath & "types/SchemaType.java" : include "java/SchemaType.java" : close
-
- create $BasePath & "types/SchemaBoolean.java" : include "java/SchemaBoolean.java" : close
- create $BasePath & "types/SchemaByte.java" : include "java/SchemaByte.java" : close
- create $BasePath & "types/SchemaShort.java" : include "java/SchemaShort.java" : close
- create $BasePath & "types/SchemaInt.java" : include "java/SchemaInt.java" : close
- create $BasePath & "types/SchemaLong.java" : include "java/SchemaLong.java" : close
-
- create $BasePath & "types/SchemaInteger.java" : include "java/SchemaInteger.java" : close
- create $BasePath & "types/SchemaDecimal.java" : include "java/SchemaDecimal.java" : close
- create $BasePath & "types/SchemaDouble.java" : include "java/SchemaDouble.java" : close
- create $BasePath & "types/SchemaFloat.java" : include "java/SchemaFloat.java" : close
-
- create $BasePath & "types/SchemaDateTime.java" : include "java/SchemaDateTime.java" : close
-
- create $BasePath & "types/SchemaString.java" : include "java/SchemaString.java" : close
- create $BasePath & "types/SchemaNormalizedString.java" : include "java/SchemaNormalizedString.java" : close
- create $BasePath & "types/SchemaToken.java" : include "java/SchemaToken.java" : close
- create $BasePath & "types/SchemaLanguage.java" : include "java/SchemaLanguage.java" : close
- create $BasePath & "types/SchemaName.java" : include "java/SchemaName.java" : close
- create $BasePath & "types/SchemaNMToken.java" : include "java/SchemaNMToken.java" : close
- create $BasePath & "types/SchemaNCName.java" : include "java/SchemaNCName.java" : close
- create $BasePath & "types/SchemaID.java" : include "java/SchemaID.java" : close
- create $BasePath & "types/SchemaIDRef.java" : include "java/SchemaIDRef.java" : close
- create $BasePath & "types/SchemaEntity.java" : include "java/SchemaEntity.java" : close
-
- create $BasePath & "Document.java" : include "java/Document.java" : close
- create $BasePath & "Node.java" : include "java/Node.java" : close
- create $BasePath & "XmlException.java" : include "java/XmlException.java" : close
- ]