com.sun.tools.internal.xjc.util.DOMUtils Java Examples
The following examples show how to use
com.sun.tools.internal.xjc.util.DOMUtils.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: PluginImpl.java From openjdk-jdk8u with GNU General Public License v2.0 | 6 votes |
public boolean run(Outline model, Options opt, ErrorHandler errorHandler) { for( ClassOutline co : model.getClasses() ) { CPluginCustomization c = co.target.getCustomizations().find(Const.NS,"code"); if(c==null) continue; // no customization --- nothing to inject here c.markAsAcknowledged(); // TODO: ideally you should validate this DOM element to make sure // that there's no typo/etc. JAXP 1.3 can do this very easily. String codeFragment = DOMUtils.getElementText(c.element); // inject the specified code fragment into the implementation class. co.implClass.direct(codeFragment); } return true; }
Example #2
Source File: Internalizer.java From TencentKona-8 with GNU General Public License v2.0 | 6 votes |
/** * Moves JAXWS customizations under their respective target nodes. */ private void insertBinding(@NotNull Element bindings, @NotNull Node target) { if ("bindings".equals(bindings.getLocalName())) { Element[] children = DOMUtils.getChildElements(bindings); for (Element item : children) { if ("bindings".equals(item.getLocalName())) { //done } else { moveUnder(item, (Element) target); } } } else { moveUnder(bindings, (Element) target); } }
Example #3
Source File: WSDLInternalizationLogic.java From TencentKona-8 with GNU General Public License v2.0 | 6 votes |
@Override public Element refineSchemaTarget(Element target) { // look for existing xs:annotation Element annotation = DOMUtils.getFirstChildElement(target, Constants.NS_XSD, "annotation"); if(annotation==null) // none exists. need to make one annotation = insertXMLSchemaElement( target, "annotation" ); // then look for appinfo Element appinfo = DOMUtils.getFirstChildElement(annotation, Constants.NS_XSD, "appinfo" ); if(appinfo==null) // none exists. need to make one appinfo = insertXMLSchemaElement( annotation, "appinfo" ); return appinfo; }
Example #4
Source File: PluginImpl.java From jdk8u60 with GNU General Public License v2.0 | 6 votes |
public boolean run(Outline model, Options opt, ErrorHandler errorHandler) { for( ClassOutline co : model.getClasses() ) { CPluginCustomization c = co.target.getCustomizations().find(Const.NS,"code"); if(c==null) continue; // no customization --- nothing to inject here c.markAsAcknowledged(); // TODO: ideally you should validate this DOM element to make sure // that there's no typo/etc. JAXP 1.3 can do this very easily. String codeFragment = DOMUtils.getElementText(c.element); // inject the specified code fragment into the implementation class. co.implClass.direct(codeFragment); } return true; }
Example #5
Source File: Internalizer.java From openjdk-8 with GNU General Public License v2.0 | 6 votes |
/** * Moves JAXWS customizations under their respective target nodes. */ private void insertBinding(@NotNull Element bindings, @NotNull Node target) { if ("bindings".equals(bindings.getLocalName())) { Element[] children = DOMUtils.getChildElements(bindings); for (Element item : children) { if ("bindings".equals(item.getLocalName())) { //done } else { moveUnder(item, (Element) target); } } } else { moveUnder(bindings, (Element) target); } }
Example #6
Source File: Internalizer.java From jdk8u60 with GNU General Public License v2.0 | 6 votes |
public Element refineSchemaTarget(Element target) { // look for existing xs:annotation Element annotation = DOMUtils.getFirstChildElement(target, Constants.NS_XSD, "annotation"); if (annotation == null) { // none exists. need to make one annotation = insertXMLSchemaElement(target, "annotation"); } // then look for appinfo Element appinfo = DOMUtils.getFirstChildElement(annotation, Constants.NS_XSD, "appinfo"); if (appinfo == null) { // none exists. need to make one appinfo = insertXMLSchemaElement(annotation, "appinfo"); } return appinfo; }
Example #7
Source File: Internalizer.java From jdk8u60 with GNU General Public License v2.0 | 6 votes |
/** * Moves JAXWS customizations under their respective target nodes. */ private void insertBinding(@NotNull Element bindings, @NotNull Node target) { if ("bindings".equals(bindings.getLocalName())) { Element[] children = DOMUtils.getChildElements(bindings); for (Element item : children) { if ("bindings".equals(item.getLocalName())) { //done } else { moveUnder(item, (Element) target); } } } else { moveUnder(bindings, (Element) target); } }
Example #8
Source File: Internalizer.java From openjdk-jdk8u with GNU General Public License v2.0 | 6 votes |
/** * Moves JAXWS customizations under their respective target nodes. */ private void insertBinding(@NotNull Element bindings, @NotNull Node target) { if ("bindings".equals(bindings.getLocalName())) { Element[] children = DOMUtils.getChildElements(bindings); for (Element item : children) { if ("bindings".equals(item.getLocalName())) { //done } else { moveUnder(item, (Element) target); } } } else { moveUnder(bindings, (Element) target); } }
Example #9
Source File: WSDLInternalizationLogic.java From openjdk-8 with GNU General Public License v2.0 | 6 votes |
@Override public Element refineSchemaTarget(Element target) { // look for existing xs:annotation Element annotation = DOMUtils.getFirstChildElement(target, Constants.NS_XSD, "annotation"); if(annotation==null) // none exists. need to make one annotation = insertXMLSchemaElement( target, "annotation" ); // then look for appinfo Element appinfo = DOMUtils.getFirstChildElement(annotation, Constants.NS_XSD, "appinfo" ); if(appinfo==null) // none exists. need to make one appinfo = insertXMLSchemaElement( annotation, "appinfo" ); return appinfo; }
Example #10
Source File: PluginImpl.java From TencentKona-8 with GNU General Public License v2.0 | 6 votes |
public boolean run(Outline model, Options opt, ErrorHandler errorHandler) { for( ClassOutline co : model.getClasses() ) { CPluginCustomization c = co.target.getCustomizations().find(Const.NS,"code"); if(c==null) continue; // no customization --- nothing to inject here c.markAsAcknowledged(); // TODO: ideally you should validate this DOM element to make sure // that there's no typo/etc. JAXP 1.3 can do this very easily. String codeFragment = DOMUtils.getElementText(c.element); // inject the specified code fragment into the implementation class. co.implClass.direct(codeFragment); } return true; }
Example #11
Source File: PluginImpl.java From openjdk-8 with GNU General Public License v2.0 | 6 votes |
public boolean run(Outline model, Options opt, ErrorHandler errorHandler) { for( ClassOutline co : model.getClasses() ) { CPluginCustomization c = co.target.getCustomizations().find(Const.NS,"code"); if(c==null) continue; // no customization --- nothing to inject here c.markAsAcknowledged(); // TODO: ideally you should validate this DOM element to make sure // that there's no typo/etc. JAXP 1.3 can do this very easily. String codeFragment = DOMUtils.getElementText(c.element); // inject the specified code fragment into the implementation class. co.implClass.direct(codeFragment); } return true; }
Example #12
Source File: WSDLInternalizationLogic.java From jdk8u60 with GNU General Public License v2.0 | 6 votes |
@Override public Element refineSchemaTarget(Element target) { // look for existing xs:annotation Element annotation = DOMUtils.getFirstChildElement(target, Constants.NS_XSD, "annotation"); if(annotation==null) // none exists. need to make one annotation = insertXMLSchemaElement( target, "annotation" ); // then look for appinfo Element appinfo = DOMUtils.getFirstChildElement(annotation, Constants.NS_XSD, "appinfo" ); if(appinfo==null) // none exists. need to make one appinfo = insertXMLSchemaElement( annotation, "appinfo" ); return appinfo; }
Example #13
Source File: Internalizer.java From openjdk-jdk8u with GNU General Public License v2.0 | 6 votes |
public Element refineSchemaTarget(Element target) { // look for existing xs:annotation Element annotation = DOMUtils.getFirstChildElement(target, Constants.NS_XSD, "annotation"); if (annotation == null) { // none exists. need to make one annotation = insertXMLSchemaElement(target, "annotation"); } // then look for appinfo Element appinfo = DOMUtils.getFirstChildElement(annotation, Constants.NS_XSD, "appinfo"); if (appinfo == null) { // none exists. need to make one appinfo = insertXMLSchemaElement(annotation, "appinfo"); } return appinfo; }
Example #14
Source File: PluginImpl.java From openjdk-8-source with GNU General Public License v2.0 | 6 votes |
public boolean run(Outline model, Options opt, ErrorHandler errorHandler) { for( ClassOutline co : model.getClasses() ) { CPluginCustomization c = co.target.getCustomizations().find(Const.NS,"code"); if(c==null) continue; // no customization --- nothing to inject here c.markAsAcknowledged(); // TODO: ideally you should validate this DOM element to make sure // that there's no typo/etc. JAXP 1.3 can do this very easily. String codeFragment = DOMUtils.getElementText(c.element); // inject the specified code fragment into the implementation class. co.implClass.direct(codeFragment); } return true; }
Example #15
Source File: WSDLInternalizationLogic.java From openjdk-jdk8u with GNU General Public License v2.0 | 6 votes |
@Override public Element refineSchemaTarget(Element target) { // look for existing xs:annotation Element annotation = DOMUtils.getFirstChildElement(target, Constants.NS_XSD, "annotation"); if(annotation==null) // none exists. need to make one annotation = insertXMLSchemaElement( target, "annotation" ); // then look for appinfo Element appinfo = DOMUtils.getFirstChildElement(annotation, Constants.NS_XSD, "appinfo" ); if(appinfo==null) // none exists. need to make one appinfo = insertXMLSchemaElement( annotation, "appinfo" ); return appinfo; }
Example #16
Source File: Internalizer.java From TencentKona-8 with GNU General Public License v2.0 | 6 votes |
public Element refineSchemaTarget(Element target) { // look for existing xs:annotation Element annotation = DOMUtils.getFirstChildElement(target, Constants.NS_XSD, "annotation"); if (annotation == null) { // none exists. need to make one annotation = insertXMLSchemaElement(target, "annotation"); } // then look for appinfo Element appinfo = DOMUtils.getFirstChildElement(annotation, Constants.NS_XSD, "appinfo"); if (appinfo == null) { // none exists. need to make one appinfo = insertXMLSchemaElement(annotation, "appinfo"); } return appinfo; }
Example #17
Source File: WSDLInternalizationLogic.java From openjdk-8-source with GNU General Public License v2.0 | 6 votes |
@Override public Element refineSchemaTarget(Element target) { // look for existing xs:annotation Element annotation = DOMUtils.getFirstChildElement(target, Constants.NS_XSD, "annotation"); if(annotation==null) // none exists. need to make one annotation = insertXMLSchemaElement( target, "annotation" ); // then look for appinfo Element appinfo = DOMUtils.getFirstChildElement(annotation, Constants.NS_XSD, "appinfo" ); if(appinfo==null) // none exists. need to make one appinfo = insertXMLSchemaElement( annotation, "appinfo" ); return appinfo; }
Example #18
Source File: Internalizer.java From openjdk-8-source with GNU General Public License v2.0 | 6 votes |
public Element refineSchemaTarget(Element target) { // look for existing xs:annotation Element annotation = DOMUtils.getFirstChildElement(target, Constants.NS_XSD, "annotation"); if (annotation == null) { // none exists. need to make one annotation = insertXMLSchemaElement(target, "annotation"); } // then look for appinfo Element appinfo = DOMUtils.getFirstChildElement(annotation, Constants.NS_XSD, "appinfo"); if (appinfo == null) { // none exists. need to make one appinfo = insertXMLSchemaElement(annotation, "appinfo"); } return appinfo; }
Example #19
Source File: Internalizer.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 6 votes |
/** * Moves JAXWS customizations under their respective target nodes. */ private void insertBinding(@NotNull Element bindings, @NotNull Node target) { if ("bindings".equals(bindings.getLocalName())) { Element[] children = DOMUtils.getChildElements(bindings); for (Element item : children) { if ("bindings".equals(item.getLocalName())) { //done } else { moveUnder(item, (Element) target); } } } else { moveUnder(bindings, (Element) target); } }
Example #20
Source File: Internalizer.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 6 votes |
public Element refineSchemaTarget(Element target) { // look for existing xs:annotation Element annotation = DOMUtils.getFirstChildElement(target, Constants.NS_XSD, "annotation"); if (annotation == null) { // none exists. need to make one annotation = insertXMLSchemaElement(target, "annotation"); } // then look for appinfo Element appinfo = DOMUtils.getFirstChildElement(annotation, Constants.NS_XSD, "appinfo"); if (appinfo == null) { // none exists. need to make one appinfo = insertXMLSchemaElement(annotation, "appinfo"); } return appinfo; }
Example #21
Source File: Internalizer.java From openjdk-8-source with GNU General Public License v2.0 | 6 votes |
/** * Moves JAXWS customizations under their respective target nodes. */ private void insertBinding(@NotNull Element bindings, @NotNull Node target) { if ("bindings".equals(bindings.getLocalName())) { Element[] children = DOMUtils.getChildElements(bindings); for (Element item : children) { if ("bindings".equals(item.getLocalName())) { //done } else { moveUnder(item, (Element) target); } } } else { moveUnder(bindings, (Element) target); } }
Example #22
Source File: WSDLInternalizationLogic.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 6 votes |
@Override public Element refineSchemaTarget(Element target) { // look for existing xs:annotation Element annotation = DOMUtils.getFirstChildElement(target, Constants.NS_XSD, "annotation"); if(annotation==null) // none exists. need to make one annotation = insertXMLSchemaElement( target, "annotation" ); // then look for appinfo Element appinfo = DOMUtils.getFirstChildElement(annotation, Constants.NS_XSD, "appinfo" ); if(appinfo==null) // none exists. need to make one appinfo = insertXMLSchemaElement( annotation, "appinfo" ); return appinfo; }
Example #23
Source File: PluginImpl.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 6 votes |
public boolean run(Outline model, Options opt, ErrorHandler errorHandler) { for( ClassOutline co : model.getClasses() ) { CPluginCustomization c = co.target.getCustomizations().find(Const.NS,"code"); if(c==null) continue; // no customization --- nothing to inject here c.markAsAcknowledged(); // TODO: ideally you should validate this DOM element to make sure // that there's no typo/etc. JAXP 1.3 can do this very easily. String codeFragment = DOMUtils.getElementText(c.element); // inject the specified code fragment into the implementation class. co.implClass.direct(codeFragment); } return true; }
Example #24
Source File: PluginImpl.java From hottub with GNU General Public License v2.0 | 6 votes |
public boolean run(Outline model, Options opt, ErrorHandler errorHandler) { for( ClassOutline co : model.getClasses() ) { CPluginCustomization c = co.target.getCustomizations().find(Const.NS,"code"); if(c==null) continue; // no customization --- nothing to inject here c.markAsAcknowledged(); // TODO: ideally you should validate this DOM element to make sure // that there's no typo/etc. JAXP 1.3 can do this very easily. String codeFragment = DOMUtils.getElementText(c.element); // inject the specified code fragment into the implementation class. co.implClass.direct(codeFragment); } return true; }
Example #25
Source File: WSDLInternalizationLogic.java From hottub with GNU General Public License v2.0 | 6 votes |
@Override public Element refineSchemaTarget(Element target) { // look for existing xs:annotation Element annotation = DOMUtils.getFirstChildElement(target, Constants.NS_XSD, "annotation"); if(annotation==null) // none exists. need to make one annotation = insertXMLSchemaElement( target, "annotation" ); // then look for appinfo Element appinfo = DOMUtils.getFirstChildElement(annotation, Constants.NS_XSD, "appinfo" ); if(appinfo==null) // none exists. need to make one appinfo = insertXMLSchemaElement( annotation, "appinfo" ); return appinfo; }
Example #26
Source File: Internalizer.java From hottub with GNU General Public License v2.0 | 6 votes |
public Element refineSchemaTarget(Element target) { // look for existing xs:annotation Element annotation = DOMUtils.getFirstChildElement(target, Constants.NS_XSD, "annotation"); if (annotation == null) { // none exists. need to make one annotation = insertXMLSchemaElement(target, "annotation"); } // then look for appinfo Element appinfo = DOMUtils.getFirstChildElement(annotation, Constants.NS_XSD, "appinfo"); if (appinfo == null) { // none exists. need to make one appinfo = insertXMLSchemaElement(annotation, "appinfo"); } return appinfo; }
Example #27
Source File: Internalizer.java From hottub with GNU General Public License v2.0 | 6 votes |
/** * Moves JAXWS customizations under their respective target nodes. */ private void insertBinding(@NotNull Element bindings, @NotNull Node target) { if ("bindings".equals(bindings.getLocalName())) { Element[] children = DOMUtils.getChildElements(bindings); for (Element item : children) { if ("bindings".equals(item.getLocalName())) { //done } else { moveUnder(item, (Element) target); } } } else { moveUnder(bindings, (Element) target); } }
Example #28
Source File: Internalizer.java From openjdk-jdk9 with GNU General Public License v2.0 | 6 votes |
/** * Moves JAXWS customizations under their respective target nodes. */ private void insertBinding(@NotNull Element bindings, @NotNull Node target) { if ("bindings".equals(bindings.getLocalName())) { Element[] children = DOMUtils.getChildElements(bindings); for (Element item : children) { if ("bindings".equals(item.getLocalName())) { //done } else { moveUnder(item, (Element) target); } } } else { moveUnder(bindings, (Element) target); } }
Example #29
Source File: Internalizer.java From openjdk-jdk9 with GNU General Public License v2.0 | 6 votes |
public Element refineSchemaTarget(Element target) { // look for existing xs:annotation Element annotation = DOMUtils.getFirstChildElement(target, Constants.NS_XSD, "annotation"); if (annotation == null) { // none exists. need to make one annotation = insertXMLSchemaElement(target, "annotation"); } // then look for appinfo Element appinfo = DOMUtils.getFirstChildElement(annotation, Constants.NS_XSD, "appinfo"); if (appinfo == null) { // none exists. need to make one appinfo = insertXMLSchemaElement(annotation, "appinfo"); } return appinfo; }
Example #30
Source File: WSDLInternalizationLogic.java From openjdk-jdk9 with GNU General Public License v2.0 | 6 votes |
@Override public Element refineSchemaTarget(Element target) { // look for existing xs:annotation Element annotation = DOMUtils.getFirstChildElement(target, Constants.NS_XSD, "annotation"); if(annotation==null) // none exists. need to make one annotation = insertXMLSchemaElement( target, "annotation" ); // then look for appinfo Element appinfo = DOMUtils.getFirstChildElement(annotation, Constants.NS_XSD, "appinfo" ); if(appinfo==null) // none exists. need to make one appinfo = insertXMLSchemaElement( annotation, "appinfo" ); return appinfo; }