Deprecate all MD-SAL APIs
[controller.git] / opendaylight / md-sal / sal-common-api / src / main / java / org / opendaylight / controller / md / sal / common / api / data / ReadFailedException.java
1 /*
2  * Copyright (c) 2014 Brocade Communications Systems, Inc. and others.  All rights reserved.
3  *
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
7  */
8
9 package org.opendaylight.controller.md.sal.common.api.data;
10
11 import org.opendaylight.yangtools.util.concurrent.ExceptionMapper;
12 import org.opendaylight.yangtools.yang.common.OperationFailedException;
13 import org.opendaylight.yangtools.yang.common.RpcError;
14
15 /**
16  * An exception for a failed read.
17  *
18  * @deprecated Use {@link org.opendaylight.mdsal.common.api.ReadFailedException} instead.
19  */
20 @Deprecated
21 public class ReadFailedException extends OperationFailedException {
22
23     private static final long serialVersionUID = 1L;
24
25     public static final ExceptionMapper<ReadFailedException> MAPPER =
26         new ExceptionMapper<ReadFailedException>("read", ReadFailedException.class) {
27             @Override
28             protected ReadFailedException newWithCause(String message, Throwable cause) {
29                 return new ReadFailedException(message, cause);
30             }
31     };
32
33     public ReadFailedException(String message, RpcError... errors) {
34         super(message, errors);
35     }
36
37     public ReadFailedException(String message, Throwable cause, RpcError... errors) {
38         super(message, cause, errors);
39     }
40 }