Code Review
/
yangtools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Introduce formatting methods for SourceException
[yangtools.git]
/
yang
/
yang-parser-impl
/
src
/
main
/
java
/
org
/
opendaylight
/
yangtools
/
yang
/
parser
/
spi
/
meta
/
MissingSubstatementException.java
diff --git
a/yang/yang-parser-impl/src/main/java/org/opendaylight/yangtools/yang/parser/spi/meta/MissingSubstatementException.java
b/yang/yang-parser-impl/src/main/java/org/opendaylight/yangtools/yang/parser/spi/meta/MissingSubstatementException.java
index a2c45721f9d82c24351a27ab5d6aee8f1235dabe..d2570dbed771952e82ec106cdf2e2196631eff87 100644
(file)
--- a/
yang/yang-parser-impl/src/main/java/org/opendaylight/yangtools/yang/parser/spi/meta/MissingSubstatementException.java
+++ b/
yang/yang-parser-impl/src/main/java/org/opendaylight/yangtools/yang/parser/spi/meta/MissingSubstatementException.java
@@
-12,16
+12,22
@@
import org.opendaylight.yangtools.yang.parser.spi.source.SourceException;
import org.opendaylight.yangtools.yang.parser.spi.source.StatementSourceReference;
/**
import org.opendaylight.yangtools.yang.parser.spi.source.StatementSourceReference;
/**
- *
* Thrown when there was Missing element in yang file
* Thrown when there was Missing element in yang file
- *
*/
public class MissingSubstatementException extends SourceException {
*/
public class MissingSubstatementException extends SourceException {
- public MissingSubstatementException(@Nonnull String message, @Nonnull StatementSourceReference source) {
+ private static final long serialVersionUID = 1L;
+
+ public MissingSubstatementException(@Nonnull final String message, @Nonnull final StatementSourceReference source) {
super(message, source);
}
super(message, source);
}
- public MissingSubstatementException(@Nonnull String message, @Nonnull StatementSourceReference source, Throwable cause) {
+ public MissingSubstatementException(@Nonnull final String message, @Nonnull final StatementSourceReference source,
+ final Throwable cause) {
super(message, source, cause);
}
super(message, source, cause);
}
+
+ public MissingSubstatementException(@Nonnull final StatementSourceReference source, @Nonnull final String format,
+ final Object... args) {
+ this(String.format(format, args), source);
+ }
}
}