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============================================
38 package org.onap.portalapp.portal.transport;
40 import java.util.ArrayList;
41 import java.util.List;
44 * User description which we receive in response from request to remote
45 * application: applicationsRestClientService.get(RemoteUserWithRoles[].class,
46 * appId, "/users"). It contains the most important info about remote
47 * application user including his roles in this application.
49 public class RemoteUserWithRoles {
53 private Long managerId;
55 private String firstName;
57 private String middleInitial;
59 private String lastName;
67 private String orgUserId;
69 private String orgCode;
71 private String orgManagerUserId;
73 private String jobTitle;
75 private String loginId;
77 private Boolean active;
79 private List<RemoteRole> roles = new ArrayList<RemoteRole>();
81 public Long getOrgId() {
85 public void setOrgId(Long orgId) {
89 public Long getManagerId() {
93 public void setManagerId(Long managerId) {
94 this.managerId = managerId;
97 public String getFirstName() {
101 public void setFirstName(String firstName) {
102 this.firstName = firstName;
105 public String getMiddleInitial() {
106 return middleInitial;
109 public void setMiddleInitial(String middleInitial) {
110 this.middleInitial = middleInitial;
113 public String getLastName() {
117 public void setLastName(String lastName) {
118 this.lastName = lastName;
121 public String getPhone() {
125 public void setPhone(String phone) {
129 public String getEmail() {
133 public void setEmail(String email) {
137 public String getHrid() {
141 public void setHrid(String hrid) {
145 public String getOrgUserId() {
149 public void setOrgUserId(String orgUserId) {
150 if(this.orgUserId == null)
151 this.orgUserId = orgUserId;
154 public String getOrgCode() {
158 public void setOrgCode(String orgCode) {
159 this.orgCode = orgCode;
162 public String getOrgManagerUserId() {
163 return orgManagerUserId;
166 public void setOrgManagerUserId(String orgManagerUserId) {
167 this.orgManagerUserId = orgManagerUserId;
170 public String getJobTitle() {
174 public void setJobTitle(String jobTitle) {
175 this.jobTitle = jobTitle;
178 public String getLoginId() {
182 public void setLoginId(String loginId) {
183 this.loginId = loginId;
186 public Boolean getActive() {
190 public void setActive(Boolean active) {
191 this.active = active;
194 public List<RemoteRole> getRoles() {
198 public void setRoles(List<RemoteRole> roles) {
203 public String toString() {
204 return "RemoteUserWithRoles [orgId=" + orgId + ", managerId=" + managerId + ", firstName=" + firstName
205 + ", middleInitial=" + middleInitial + ", lastName=" + lastName + ", phone=" + phone + ", email="
206 + email + ", hrid=" + hrid + ", orgUserId=" + orgUserId + ", orgCode=" + orgCode + ", orgManagerUserId="
207 + orgManagerUserId + ", jobTitle=" + jobTitle + ", loginId=" + loginId + ", active=" + active
208 + ", roles=" + roles + "]";