2 * ============LICENSE_START==========================================
4 * ===================================================================
5 * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
6 * ===================================================================
8 * Unless otherwise specified, all software contained herein is licensed
9 * under the Apache License, Version 2.0 (the "License");
10 * you may not use this software except in compliance with the License.
11 * You may obtain a copy of the License at
13 * http://www.apache.org/licenses/LICENSE-2.0
15 * Unless required by applicable law or agreed to in writing, software
16 * distributed under the License is distributed on an "AS IS" BASIS,
17 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18 * See the License for the specific language governing permissions and
19 * limitations under the License.
21 * Unless otherwise specified, all documentation contained herein is licensed
22 * under the Creative Commons License, Attribution 4.0 Intl. (the "License");
23 * you may not use this documentation except in compliance with the License.
24 * You may obtain a copy of the License at
26 * https://creativecommons.org/licenses/by/4.0/
28 * Unless required by applicable law or agreed to in writing, documentation
29 * distributed under the License is distributed on an "AS IS" BASIS,
30 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
31 * See the License for the specific language governing permissions and
32 * limitations under the License.
34 * ============LICENSE_END============================================
36 * ECOMP is a trademark and service mark of AT&T Intellectual Property.
38 package org.onap.portalapp.portal.transport;
40 import java.io.Serializable;
41 import java.util.Date;
42 import java.util.SortedSet;
43 import java.util.TreeSet;
45 public class CentralRole implements Serializable {
47 private static final long serialVersionUID = -9210905386086213882L;
50 private Date modified;
51 private Long createdId;
52 private Long modifiedId;
56 private boolean active;
57 private Integer priority;
59 private SortedSet<CentralRoleFunction> roleFunctions = new TreeSet<>();
61 private SortedSet<CentralRole> childRoles = new TreeSet<>();
63 private SortedSet<CentralRole> parentRoles = new TreeSet<>();
69 public CentralRole(Long id, String name, boolean active, Integer priority,
70 SortedSet<CentralRoleFunction> roleFunctions) {
75 this.priority = priority;
76 this.roleFunctions = roleFunctions;
81 public CentralRole(Long id, Date created, Date modified, Long createdId, Long modifiedId, Long rowNum, String name,
82 boolean active, Integer priority, SortedSet<CentralRoleFunction> roleFunctions,
83 SortedSet<CentralRole> childRoles, SortedSet<CentralRole> parentRoles) {
86 this.created = created;
87 this.modified = modified;
88 this.createdId = createdId;
89 this.modifiedId = modifiedId;
93 this.priority = priority;
94 this.roleFunctions = roleFunctions;
95 this.childRoles = childRoles;
96 this.parentRoles = parentRoles;
102 public Long getId() {
110 public void setId(Long id) {
115 * @return the created
117 public Date getCreated() {
125 public void setCreated(Date created) {
126 this.created = created;
130 * @return the modified
132 public Date getModified() {
138 * the modified to set
140 public void setModified(Date modified) {
141 this.modified = modified;
145 * @return the createdId
147 public Long getCreatedId() {
153 * the createdId to set
155 public void setCreatedId(Long createdId) {
156 this.createdId = createdId;
160 * @return the modifiedId
162 public Long getModifiedId() {
168 * the modifiedId to set
170 public void setModifiedId(Long modifiedId) {
171 this.modifiedId = modifiedId;
177 public Long getRowNum() {
185 public void setRowNum(Long rowNum) {
186 this.rowNum = rowNum;
192 public String getName() {
200 public void setName(String name) {
207 public boolean isActive() {
215 public void setActive(boolean active) {
216 this.active = active;
220 * @return the priority
222 public Integer getPriority() {
228 * the priority to set
230 public void setPriority(Integer priority) {
231 this.priority = priority;
235 * @return the roleFunctions
237 public SortedSet<CentralRoleFunction> getRoleFunctions() {
238 return roleFunctions;
242 * @param roleFunctions
243 * the roleFunctions to set
245 public void setRoleFunctions(SortedSet<CentralRoleFunction> roleFunctions) {
246 this.roleFunctions = roleFunctions;
250 * @return the childRoles
252 public SortedSet<CentralRole> getChildRoles() {
258 * the childRoles to set
260 public void setChildRoles(SortedSet<CentralRole> childRoles) {
261 this.childRoles = childRoles;
265 * @return the parentRoles
267 public SortedSet<CentralRole> getParentRoles() {
273 * the parentRoles to set
275 public void setParentRoles(SortedSet<CentralRole> parentRoles) {
276 this.parentRoles = parentRoles;