1 19 27 28 package org.netbeans.modules.websvc.customization.model.impl; 29 30 31 import org.netbeans.modules.websvc.customization.model.EnableMIMEContent; 32 import org.netbeans.modules.xml.wsdl.model.WSDLModel; 33 import org.netbeans.modules.xml.wsdl.model.visitor.WSDLVisitor; 34 import org.w3c.dom.Element ; 35 36 40 public class EnableMIMEContentImpl extends CustomizationComponentImpl 41 implements EnableMIMEContent{ 42 43 44 public EnableMIMEContentImpl(WSDLModel model, Element e) { 45 super(model, e); 46 } 47 48 public EnableMIMEContentImpl(WSDLModel model){ 49 this(model, createPrefixedElement(JAXWSQName.ENABLEMIMECONTENT.getQName(), model)); 50 } 51 52 public void setEnabled(boolean enable) { 53 setText(this.ENABLE_MIME_CONTENT_VALUE_PROPERTY, Boolean.toString(enable)); 54 } 55 56 public boolean isEnabled() { 57 String value = getText().trim(); 58 if(value.equals("true")){ 59 return true; 60 } 61 return false; 62 } 63 64 public void accept(WSDLVisitor visitor) { 65 visitor.visit(this); 66 } 67 68 } 69 | Popular Tags |