Rename MainNode methods
[yangtools.git] / yang / yang-parser-impl / src / main / java / org / opendaylight / yangtools / yang / parser / util / YangParseException.java
1 /*
2  * Copyright (c) 2013 Cisco 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 package org.opendaylight.yangtools.yang.parser.util;
9
10 /**
11  * @deprecated This exception is not produced anywhere and is scheduled for removal.
12  */
13 // TODO: switch to checked exception, add YangSemanticException
14 @Deprecated
15 public class YangParseException extends RuntimeException {
16     private static final long serialVersionUID = 1239548963471793178L;
17
18     public YangParseException(final String errorMsg) {
19         super(errorMsg);
20     }
21
22     public YangParseException(final String errorMsg, final Exception exception) {
23         super(errorMsg, exception);
24     }
25
26     public YangParseException(final String moduleName, final int line, final String errorMsg) {
27         super("Error in module '" + moduleName + "' at line " + line + ": " + errorMsg);
28     }
29
30     public YangParseException(final String moduleName, final int line, final String errorMsg, final Exception exception) {
31         super("Error in module '" + moduleName + "' at line " + line + ": " + errorMsg, exception);
32     }
33 }