1 19 20 package org.netbeans.modules.xml.wsdl.model.impl; 21 22 import java.util.Collection ; 23 import org.netbeans.modules.xml.wsdl.model.Message; 24 import org.netbeans.modules.xml.wsdl.model.Part; 25 import org.netbeans.modules.xml.wsdl.model.WSDLModel; 26 import org.netbeans.modules.xml.wsdl.model.visitor.WSDLVisitor; 27 import org.w3c.dom.Element ; 28 29 33 public class MessageImpl extends NamedImpl implements Message { 34 35 36 public MessageImpl(WSDLModel model, Element e) { 37 super(model, e); 38 } 39 public MessageImpl(WSDLModel model) { 40 this(model, createNewElement(WSDLQNames.MESSAGE.getQName(), model)); 41 } 42 43 public Collection <Part> getParts() { 44 return getChildren(Part.class); 45 } 46 47 public void removePart(Part part) { 48 removeChild(PART_PROPERTY, part); 49 } 50 51 public void addPart(Part part) { 52 appendChild(PART_PROPERTY, part); 53 } 54 55 public void accept(WSDLVisitor visitor) { 56 visitor.visit(this); 57 } 58 } 59 | Popular Tags |