1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18 package org.opensaml.xacml.policy.impl;
19
20 import java.util.List;
21
22 import org.opensaml.xacml.policy.AttributeDesignatorType;
23 import org.opensaml.xml.XMLObject;
24 import org.opensaml.xml.schema.XSBooleanValue;
25 import org.opensaml.xml.util.LazyList;
26 import org.opensaml.xml.validation.AbstractValidatingXMLObject;
27
28
29
30
31 public class AttributeDesignatorTypeImpl extends AbstractValidatingXMLObject
32 implements AttributeDesignatorType {
33
34
35 private String attributeId;
36
37
38 private String dataType;
39
40
41 private String issuer;
42
43
44 private XSBooleanValue mustBePresentXS = null;
45
46
47
48
49
50
51
52
53
54
55
56 protected AttributeDesignatorTypeImpl(String namespaceURI,
57 String elementLocalName, String namespacePrefix) {
58 super(namespaceURI, elementLocalName, namespacePrefix);
59 mustBePresentXS = XSBooleanValue.valueOf("false");
60 }
61
62
63 public String getAttributeId() {
64 return attributeId;
65 }
66
67
68 public String getDataType() {
69 return dataType;
70 }
71
72
73 public String getIssuer() {
74 return issuer;
75 }
76
77
78 public XSBooleanValue getMustBePresentXSBoolean() {
79 return mustBePresentXS;
80 }
81
82
83 public Boolean getMustBePresent() {
84 if (mustBePresentXS != null) {
85 return mustBePresentXS.getValue();
86 }
87 return Boolean.FALSE;
88 }
89
90
91 public void setAttribtueId(String id) {
92 this.attributeId = prepareForAssignment(this.attributeId, id);
93 }
94
95
96 public void setDataType(String type) {
97 this.dataType = prepareForAssignment(this.dataType, type);
98 }
99
100
101 public void setIssuer(String newIssuer) {
102 this.issuer = prepareForAssignment(this.issuer, newIssuer);
103 }
104
105
106 public void setMustBePresentXSBoolean(XSBooleanValue present) {
107 this.mustBePresentXS = prepareForAssignment(this.mustBePresentXS,
108 present);
109 }
110
111
112 public void setMustBePresent(Boolean present) {
113 if (present != null) {
114 this.mustBePresentXS = prepareForAssignment(this.mustBePresentXS,
115 new XSBooleanValue(present, false));
116 } else {
117 this.mustBePresentXS = prepareForAssignment(this.mustBePresentXS,
118 null);
119 }
120
121 }
122
123
124 public List<XMLObject> getOrderedChildren() {
125 return new LazyList<XMLObject>();
126 }
127
128 }