2 * Copyright 2015 Samsung Electronics All Rights Reserved.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
17 package org.oic.simulator;
20 * This class represents the resource attribute which contains attribute value
23 public class SimulatorResourceAttribute {
25 private String mName = null;
26 private AttributeValue mValue = null;
27 private AttributeProperty mProperty = null;
30 * Constructs {@SimulatorResourceAttribute}
31 * with attribute name, value and its property.
34 * Name of the attribute.
36 * Value of the attribute.
38 * Property of attribute value.
40 public SimulatorResourceAttribute(String name, AttributeValue value,
41 AttributeProperty property) {
42 mName = new String(name);
48 * Constructs {@SimulatorResourceAttribute}
49 * with attribute name, value.
52 * Name of the attribute.
54 * Value of the attribute.
56 public SimulatorResourceAttribute(String name, AttributeValue value) {
57 mName = new String(name);
63 * API to get name of attribute.
65 * @return Attribute's name.
67 public String name() {
72 * API to get value of attribute.
74 * @return Attribute's value {@AttributeValue}.
76 public AttributeValue value() {
81 * API to get property of attribute's value.
83 * @return Attribute's value property {@AttributeProperty}.
85 public AttributeProperty property() {
90 * API to set the value of attribute.
93 * Value of the attribute.
95 public void setValue(AttributeValue value) {
100 * API to set the property of attribute.
103 * Property of the attribute.
105 public void setProperty(AttributeProperty property) {
106 this.mProperty = property;