1 19 20 package org.netbeans.modules.websvc.wsitmodelext.policy.impl; 21 22 import org.netbeans.modules.websvc.wsitmodelext.policy.PolicyQName; 23 import org.netbeans.modules.websvc.wsitmodelext.policy.PolicyReference; 24 import org.netbeans.modules.xml.wsdl.model.WSDLModel; 25 import org.netbeans.modules.xml.wsdl.model.visitor.WSDLVisitor; 26 import org.w3c.dom.Element ; 27 28 32 public class PolicyReferenceImpl extends PolicyComponentImpl implements PolicyReference { 33 34 37 public PolicyReferenceImpl(WSDLModel model, Element e) { 38 super(model, e); 39 } 40 41 public PolicyReferenceImpl(WSDLModel model){ 42 this(model, createPrefixedElement(PolicyQName.POLICYREFERENCE.getQName(), model)); 43 } 44 45 @Override 46 public void accept(WSDLVisitor visitor) { 47 visitor.visit(this); 48 } 49 50 public void setDigestAlgorithm(String digestAlgorithm) { 51 setAttribute(DIGESTALGORITHM_PROPERTY, PolicyAttribute.DIGESTALGORITHM, digestAlgorithm); 52 } 53 54 public void setDigest(String digest) { 55 setAttribute(DIGEST_PROPERTY, PolicyAttribute.DIGEST, digest); 56 } 57 58 public void setPolicyURI(String policyUri) { 59 setAttribute(POLICY_URI_PROPERTY, PolicyAttribute.URI, policyUri); 60 } 61 62 public String getPolicyURI() { 63 return getAttribute(PolicyAttribute.URI); 64 } 65 66 public String getDigestAlgorithm() { 67 return getAttribute(PolicyAttribute.DIGESTALGORITHM); 68 } 69 70 public String getDigest() { 71 return getAttribute(PolicyAttribute.DIGEST); 72 } 73 74 } 75 | Popular Tags |