2 * Copyright (C) 2014 Cisco Systems, Inc.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
8 * Authors : Thomas Bachman
10 package org.opendaylight.groupbasedpolicy.renderer.opflex.lib.messages;
12 import java.util.List;
14 import org.opendaylight.groupbasedpolicy.renderer.opflex.jsonrpc.RpcMessage;
15 import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev100924.Uri;
17 import com.fasterxml.jackson.annotation.JsonIgnore;
18 import com.fasterxml.jackson.databind.JsonNode;
20 public class EndpointUndeclareRequest extends RpcMessage {
22 public static final String UNDECLARE_MESSAGE = "endpoint_undeclare";
24 static public class Params {
26 private String subject;
27 private Uri endpoint_uri;
29 public String getSubject() {
33 public void setSubject(String subject) {
34 this.subject = subject;
37 public Uri getEndpoint_uri() {
41 public void setEndpoint_uri(Uri endpoint_uri) {
42 this.endpoint_uri = endpoint_uri;
47 private String method;
48 private List<Params> params;
54 public JsonNode getId() {
59 public void setId(JsonNode id) {
64 public String getMethod() {
69 public void setMethod(String method) {
73 public List<Params> getParams() {
77 public void setParams(List<Params> params) {
82 public String getName() {
87 public void setName(String name) {
91 public EndpointUndeclareRequest(String name) {
95 public EndpointUndeclareRequest() {
96 this.name = UNDECLARE_MESSAGE;
97 this.method = UNDECLARE_MESSAGE;
101 * Minimal check on validity of message
103 * @return true if message has passed validity check
107 public boolean valid() {
110 if (params.get(0) == null)