2 * Copyright (c) 2013 Cisco Systems, Inc. and others. All rights reserved.
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 package org.opendaylight.bgpcep.programming.spi;
10 import java.util.Collection;
11 import java.util.Collections;
13 import org.opendaylight.yangtools.yang.common.RpcError;
14 import org.opendaylight.yangtools.yang.common.RpcResult;
16 public final class SuccessfulRpcResult<T> implements RpcResult<T> {
17 private final T value;
19 private SuccessfulRpcResult(final T value) {
23 public static <T> SuccessfulRpcResult<T> create(final T value) {
24 return new SuccessfulRpcResult<T>(value);
28 public boolean isSuccessful() {
33 public T getResult() {
38 public Collection<RpcError> getErrors() {
39 return Collections.emptyList();