--- /dev/null
+/*-\r
+ * ================================================================================\r
+ * ECOMP Portal\r
+ * ================================================================================\r
+ * Copyright (C) 2017 AT&T Intellectual Property\r
+ * ================================================================================\r
+ * Licensed under the Apache License, Version 2.0 (the "License");\r
+ * you may not use this file except in compliance with the License.\r
+ * You may obtain a copy of the License at\r
+ * \r
+ * http://www.apache.org/licenses/LICENSE-2.0\r
+ * \r
+ * Unless required by applicable law or agreed to in writing, software\r
+ * distributed under the License is distributed on an "AS IS" BASIS,\r
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
+ * See the License for the specific language governing permissions and\r
+ * limitations under the License.\r
+ * ================================================================================\r
+ */\r
+package org.openecomp.portalapp.portal.transport;\r
+\r
+/**\r
+ * Model of rows in the fn_app table; serialized as a message add or update an\r
+ * on-boarded application.\r
+ */\r
+public class OnboardingApp {\r
+\r
+ public Long id;\r
+\r
+ public String name;\r
+\r
+ public String imageUrl;\r
+\r
+ public String description;\r
+\r
+ public String notes;\r
+\r
+ public String url;\r
+\r
+ public String alternateUrl;\r
+\r
+ public String restUrl;\r
+\r
+ public Boolean isOpen;\r
+\r
+ public Boolean isEnabled;\r
+\r
+ public Long motsId;\r
+\r
+ public String myLoginsAppName;\r
+\r
+ public String myLoginsAppOwner;\r
+\r
+ public String username;\r
+\r
+ public String appPassword;\r
+\r
+ public String thumbnail;\r
+\r
+ public String uebTopicName;\r
+\r
+ public String uebKey;\r
+\r
+ public String uebSecret;\r
+\r
+ public Boolean restrictedApp;\r
+\r
+ /**\r
+ * Sets the name, myLoginsAppName, myLoginsAppOwner, username and\r
+ * appPassword fields to the empty string OR trims leading/trailing space,\r
+ * as appropriate.\r
+ */\r
+ public void normalize() {\r
+ this.name = (this.name == null) ? "" : this.name.trim();\r
+ this.myLoginsAppName = (this.myLoginsAppName == null) ? "" : this.myLoginsAppName.trim();\r
+ this.myLoginsAppOwner = (this.myLoginsAppOwner == null) ? "" : this.myLoginsAppOwner.trim();\r
+ this.username = (this.username == null) ? "" : this.username.trim();\r
+ this.appPassword = (this.appPassword == null) ? "" : this.appPassword.trim();\r
+ }\r
+\r
+ public void setUebTopicName(String topicName) {\r
+ this.uebTopicName = topicName;\r
+ }\r
+\r
+ public void setUebKey(String key) {\r
+ this.uebKey = key;\r
+ }\r
+\r
+ public void setUebSecret(String secret) {\r
+ this.uebSecret = secret;\r
+ }\r
+\r
+ // Hide the implementation of restricted and normal app from the front end.\r
+ // The json sent and received will include restrictedApp but not appType.\r
+\r
+ public void setRestrictedApp(Boolean restrictedApp) {\r
+ this.restrictedApp = restrictedApp;\r
+ }\r
+}\r