xjc_FEDORA_LINUX_入门技术深入解析
2023年7月3日发(作者:)
xjc(1) xjc(1)NAMExjc − Java(TM) Architecture for XML BindingBinding CompilerSpecification Version:2.0Reference Implementation (RI) Version:2.0 ea3Launching xjcThe binding compiler can be launched using the appropriatexjcshell script in thebindirectory for yourplatform. Wealso provide an Ant task to run the binding complier − see the instructions for using xjc aris/Linux%/path/to/jaxb/bin/ −helpForWindowsNT/2000/XP>c: −helpOutputUsage: xjc [−options ...] ... [−b ] ...Options:−nv:do not perform strict validation of the input schema(s)−extension :allowvendor extensions − do not strictly followtheCompatibility Rules and App E.2 from the JAXB Spec−b <file>:specify external bindings files (each <file> must have its own −b)−d :generated files will go into this directory−p :specifies the target package−httpproxy :set HTTP/HTTPS is [user[:password]@]proxyHost:proxyPort−httpproxyfile <file>: set the proxy string (same format as above).−classpath :specify wheretofind user class files−catalog <file>:specify catalog files to resolveexternal entity referencessupport TR9401, XCatalog, and OASIS XML Catalog format.−readOnly :generated files will be in read−only mode−npa :suppress generation of package levelannotations (**/package−)−xmlschema :treat input as W3C XML Schema (default)−relaxng :treat input as RELAX NG (experimental,unsupported)−relaxng−compact :treat input as RELAX NG compact syntax (experimental,unsupported)−dtd :treat input as XML DTD (experimental,unsupported)−wsdl :treat input as WSDL and compile schemas inside it (experimental,unsupported)−verbose :be extra verbose−quiet :suppress compiler output−help :display this help message−version :display version informationExecute the jaxb− JAR File07 Aug 20061xjc(1) xjc(1)If all else fails, you should be able to execute thejaxb−file:ForSolaris/Linux:%java −jar $JAXB_HOME/lib/jaxb− −helpForWindows:>java −jar %JAXB_HOME%libjaxb− −helpThis is equivalent of running "" or "", and it allows you to set the JVM S−nvBy default, the XJC binding compiler performs strict validation of the source schema before pro-cessing it. Use this option to disable strict schema validation. This does not mean that the bindingcompiler will not perform anyvalidation, it simply means that it will perform less−strict validation.−extensionBy default, the XJC binding compiler strictly enforces the rules outlined in the Compatibility chap-ter of the JAXB Specification. Appendix E.2 defines a set of W3C XML Schema features that arenot completely supported by JAXB v1.0. In some cases, you may be allowed to use them in the"−extension" mode enabled by this switch. In the default (strict) mode, you are also limited to usingonly the binding customizations defined in the specification. By using the "−extension" switch, youwill be allowed to use the JAXB Vendor Extensions.−b <file>Specify one or more external binding files to process. (Each binding file must have it’sown"−b"switch.) The syntax of the external binding files is extremely flexible. You may have a single bind-ing file that contains customizations for multiple schemas or you can break the customizations intomultiple bindings files:xjc −b −b −b −b addition, the ordering of the schema files and binding files on the command line does not matter.−d By default, the XJC binding compiler will generate the Java content classes in the current this option to specify an alternate output output directory must already exist, theXJC binding compiler will not create it for you.−p Specifying a target package via this command−line option overrides anybinding customization forpackage name and the default package name algorithm defined in the specification.−httpproxy Specify the HTTP/HTTPS format is [user[:password]@]proxyHost[:proxyPort]. The old−hostand−portare still supported by the RI for backwards compatibility,but theyhav ebeen dep-recated. Note that the password specified with this option is an argument that is visible to otherusers who use thetopcommand, for example. For greater security,use−httpproxyfile,below.−httpproxyfile <file>Specify the HTTP/HTTPS proxy using a file. Same format as above,but the password specified inthe file is not visible to other users.−classpath Specify where to find client application class files used by theandcustomizations.07 Aug 20062xjc(1) xjc(1)−catalog <file>Specify catalog files to resolveexternal entity references. Supports TR9401, XCatalog, and OASISXML Catalog format. Please read the XML Entity and URI Resolvers document or thecata-log−resolversample application.−readOnlyBy default, the XJC binding compiler does not write−protect the Java source files it generates. Usethis option to force the XJC binding compiler to mark the generated Java sources read−only.−npaSupress the generation of package levelannotations into **/package− this switchcauses the generated code to internalize those annotations into the other generated classes.−xmlschematreat input schemas as W3C XML Schema (default). If you do not specify this switch, your inputschemas will be treated as W3C XML Schema.−relaxngTreat input schemas as RELAX NG (experimental, unsupported). Support for RELAX NG schemasis provided as a JAXB Vendor Extension.−relaxng−compactTreat input schemas as RELAX NG compact syntax(experimental, unsupported). Support forRELAX NG schemas is provided as a JAXB Vendor Extension.−dtdTreat input schemas as XML DTD (experimental, unsupported). Support for RELAX NG schemasis provided as a JAXB Vendor Extension.−wsdlTreat input as WSDL and compile schemas inside it (experimental,unsupported).−quietSuppress compiler output, such as progress information and warnings..−verboseBe extra verbose, such as printing informational messages or displaying stack traces upon someerrors..−helpDisplay a brief summary of the compiler switches.−versionDisplay the compiler version information.Specify one or more schema files to compile. If you specify a directory,then xjc will scan it for allschema files and compile y of Deprecated and RemovedCommand Line Options−host & −portThese options have been deprecated and replaced with the−httpproxyoption. For backwardscompatibility,wewill continue to support these options, but theywill no longer be documentedand may be removedfrom future releases.−use−runtimeSince the JAXB 2.0 specification has defined a portable runtime, it is no longer necessary for theJAXB RI to generate **/impl/runtime packages. Therefore, this switch is obsolete and has beenremoved.−sourceThe −source compatibility switch was introduced in the first JAXB 2.0 Early Access release. Wehave decided to remove this switch from future releases of JAXB 2.0. If you need to generate07 Aug 20063xjc(1) xjc(1)1.0.x code, please use an installation of the 1.0.x codebase.−Xlocator & −Xsync−methodsThese switches have been disabled for now. Weplan on releasing this functionality as a separatedownload in the er RestrictionsIn general, it is safest to compile all related schemas as a single unit with the same binding keep the following list of restrictions in mind when running xjc. Most of these issues only applywhen compiling multiple schemas with multiple invocations of pile multiple schemas at the same time, keep the following precedence rules for the targetJava package name in mind:1. The"−p"command line option takes the highest precedence.2. customization3. IftargetNamespaceis declared, applytargetNamespace−> Java package name algorithmdefined in the specification.4. IfnotargetNamespaceis declared, use a hardcoded package named "generated".oItisnot legaltohav emore than one per namespace, so it is impossible tohave two schemas in the same target namespace compiled into different Java schemas being compiled into the same Java package must be submitted to the XJC binding com-piler at the same time − theycannot be compiled independently and work as nt substitution groups spread across multiple schema files must be compiled at the same AlsooJAXB 2.0:*Release Notes@/webservices/docs/2.0/jaxb/*XJC@/webservices/docs/2.0/jaxb/*XJCTask@/webservices/docs/2.0/jaxb/*SchemaGen@/webservices/docs/2.0/jaxb/*schemagenTask@/webservices/docs/2.0/jaxb/*Sample Apps@/webservices/docs/2.0/jaxb/*Changelog@/webservices/docs/2.0/jaxb/AXB 1.0.x:*Release Notes@/webservices/docs/2.0/jaxb/jaxb−1_*Changelog@/webservices/docs/2.0/jaxb/07 Aug 20064xjc(1) xjc(1)oJAXB RI Extensions:*Runtime Properties@/webservices/docs/2.0/jaxb/*XJC Customizations@/webservices/docs/2.0/jaxb/*Develop Plugins@/webservices/docs/2.0/jaxb/AXB RI Schema Languages:*W3C XML Schema@/webservices/docs/2.0/jaxb/#xschema*RELAX NG@/webservices/docs/2.0/jaxb/#relaxng*DTD@/webservices/docs/2.0/jaxb/#dtdoJAXB Community:* Homepage@*Developer interest list@/servlets/ProjectMailingListList*FA Q@/faq/07 Aug 20065
发布者:admin,转转请注明出处:http://www.yc00.com/xiaochengxu/1688385005a130085.html
评论列表(0条)