+++ /dev/null
-/*******************************************************************************\r
- * ============LICENSE_START==================================================\r
- * * org.onap.dmaap\r
- * * ===========================================================================\r
- * * Copyright © 2017 AT&T Intellectual Property. All rights reserved.\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
- * * ============LICENSE_END====================================================\r
- * *\r
- * * ECOMP is a trademark and service mark of AT&T Intellectual Property.\r
- * *\r
- ******************************************************************************/\r
-\r
-\r
-package com.att.research.datarouter.provisioning.beans;\r
-\r
-import java.io.InvalidObjectException;\r
-\r
-import org.json.JSONObject;\r
-\r
-/**\r
- * The URLs associated with a Feed.\r
- * @author Robert Eby\r
- * @version $Id: FeedLinks.java,v 1.3 2013/07/05 13:48:05 eby Exp $\r
- */\r
-public class FeedLinks implements JSONable {\r
- private String self;\r
- private String publish;\r
- private String subscribe;\r
- private String log;\r
-\r
- public FeedLinks() {\r
- self = publish = subscribe = log = null;\r
- }\r
-\r
- public FeedLinks(JSONObject jo) throws InvalidObjectException {\r
- this();\r
- self = jo.getString("self");\r
- publish = jo.getString("publish");\r
- subscribe = jo.getString("subscribe");\r
- log = jo.getString("log");\r
- }\r
-\r
- public String getSelf() {\r
- return self;\r
- }\r
- public void setSelf(String self) {\r
- this.self = self;\r
- }\r
- public String getPublish() {\r
- return publish;\r
- }\r
- public void setPublish(String publish) {\r
- this.publish = publish;\r
- }\r
- public String getSubscribe() {\r
- return subscribe;\r
- }\r
- public void setSubscribe(String subscribe) {\r
- this.subscribe = subscribe;\r
- }\r
- public String getLog() {\r
- return log;\r
- }\r
- public void setLog(String log) {\r
- this.log = log;\r
- }\r
-\r
- @Override\r
- public JSONObject asJSONObject() {\r
- JSONObject jo = new JSONObject();\r
- jo.put("self", self);\r
- jo.put("publish", publish);\r
- jo.put("subscribe", subscribe);\r
- jo.put("log", log);\r
- return jo;\r
- }\r
- @Override\r
- public boolean equals(Object obj) {\r
- if (!(obj instanceof FeedLinks))\r
- return false;\r
- FeedLinks of = (FeedLinks) obj;\r
- if (!self.equals(of.self))\r
- return false;\r
- if (!publish.equals(of.publish))\r
- return false;\r
- if (!subscribe.equals(of.subscribe))\r
- return false;\r
- if (!log.equals(of.log))\r
- return false;\r
- return true;\r
- }\r
-}\r