1 19 package org.netbeans.modules.websvc.wsitmodelext.trust; 20 21 import javax.xml.namespace.QName ; 22 import java.util.HashSet ; 23 import java.util.Set ; 24 25 29 public enum TrustQName { 30 TOKENTYPE(createTrustQName("TokenType")), KEYTYPE(createTrustQName("KeyType")), KEYSIZE(createTrustQName("KeySize")); 34 public static final String TRUST_NS_URI = "http://schemas.xmlsoap.org/ws/2005/02/trust"; public static final String TRUST_NS_PREFIX = "t"; 37 public static QName createTrustQName(String localName){ 38 return new QName (TRUST_NS_URI, localName, TRUST_NS_PREFIX); 39 } 40 41 TrustQName(QName name) { 42 qName = name; 43 } 44 45 public QName getQName(){ 46 return qName; 47 } 48 private static Set <QName > qnames = null; 49 public static Set <QName > getQNames() { 50 if (qnames == null) { 51 qnames = new HashSet <QName >(); 52 for (TrustQName wq : values()) { 53 qnames.add(wq.getQName()); 54 } 55 } 56 return qnames; 57 } 58 private final QName qName; 59 60 } 61 | Popular Tags |