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;
19 import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
20 import com.fasterxml.jackson.databind.annotation.JsonSerialize;
24 public class EndpointResolveRequest extends RpcMessage {
26 public static final String EP_RESOLVE_REQUEST_MESSAGE = "endpoint_resolve";
28 static public class Params {
30 private String subject;
31 private Uri endpoint_uri;
32 private EndpointIdentity endpoint_ident;
35 public String getSubject() {
39 public void setSubject(String subject) {
40 this.subject = subject;
43 public Uri getEndpoint_uri() {
47 public void setEndpoint_uri(Uri endpoint_uri) {
48 this.endpoint_uri = endpoint_uri;
51 public EndpointIdentity getEndpoint_ident() {
52 return endpoint_ident;
55 public void setEndpoint_ident(EndpointIdentity endpoint_ident) {
56 this.endpoint_ident = endpoint_ident;
63 public void setPrr(int prr) {
69 private String method;
70 private List<Params> params;
76 public JsonNode getId() {
81 public void setId(JsonNode id) {
86 public String getMethod() {
91 public void setMethod(String method) {
95 public List<Params> getParams() {
99 public void setParams(List<Params> params) {
100 this.params = params;
104 public String getName() {
109 public void setName(String name) {
113 public EndpointResolveRequest(String name) {
117 public EndpointResolveRequest() {
118 this.name = EP_RESOLVE_REQUEST_MESSAGE;
122 * Minimal check on validity of message
124 * @return true if message has passed validity check
128 public boolean valid() {
131 if (params.get(0) == null)