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 oic.simulator.serviceprovider.model;
19 import org.oic.simulator.server.SimulatorResource.AutoUpdateType;
22 * This class represents a simulated resource. It maintains all the necessary
23 * information about the resource.
25 public class SingleResource extends Resource {
26 private boolean getAllowed;
28 private boolean putAllowed;
30 private boolean postAllowed;
32 private int automationId;
34 private boolean resourceAutomationInProgress;
36 private boolean attributeAutomationInProgress;
38 private int automationUpdateInterval;
40 private AutoUpdateType automationType;
42 public boolean isGetAllowed() {
46 public void setGetAllowed(boolean getAllowed) {
47 this.getAllowed = getAllowed;
50 public boolean isPutAllowed() {
54 public void setPutAllowed(boolean putAllowed) {
55 this.putAllowed = putAllowed;
58 public boolean isPostAllowed() {
62 public void setPostAllowed(boolean postAllowed) {
63 this.postAllowed = postAllowed;
66 public int getAutomationUpdateInterval() {
67 return automationUpdateInterval;
70 public void setAutomationUpdateInterval(int automationUpdateInterval) {
71 this.automationUpdateInterval = automationUpdateInterval;
74 public AutoUpdateType getAutomationType() {
75 return automationType;
78 public void setAutomationType(AutoUpdateType automationType) {
79 this.automationType = automationType;
82 public int getAutomationId() {
86 public void setAutomationId(int automationId) {
87 this.automationId = automationId;
90 public boolean isResourceAutomationInProgress() {
91 return resourceAutomationInProgress;
94 public void setResourceAutomationInProgress(
95 boolean resourceAutomationInProgress) {
96 this.resourceAutomationInProgress = resourceAutomationInProgress;
99 public boolean isAttributeAutomationInProgress() {
100 return attributeAutomationInProgress;
103 public void setAttributeAutomationInProgress(
104 boolean attributeAutomationInProgress) {
105 this.attributeAutomationInProgress = attributeAutomationInProgress;