Skip to content

Commit

Permalink
Added a getter on AttributeNotFoundException to retrieve attribute na…
Browse files Browse the repository at this point in the history
…me. Fixes #80.
  • Loading branch information
mbosecke committed Jun 28, 2015
1 parent 0163a9d commit 0d13fdd
Show file tree
Hide file tree
Showing 5 changed files with 702 additions and 693 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,15 @@ public class AttributeNotFoundException extends PebbleException {

private static final long serialVersionUID = 3863732457312917327L;

public AttributeNotFoundException(Throwable cause, String message) {
private final String attributeName;

public AttributeNotFoundException(Throwable cause, String message, String attributeName) {
super(cause, message);
this.attributeName = attributeName;
}

public String getAttributeName() {
return attributeName;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@

public class RootAttributeNotFoundException extends AttributeNotFoundException {

private static final long serialVersionUID = 3863732457312917327L;
private static final long serialVersionUID = 3863732457312917327L;

public RootAttributeNotFoundException(Throwable cause, String message) {
super(cause, message);
}
public RootAttributeNotFoundException(Throwable cause, String message, String attributeName) {
super(cause, message, attributeName);
}

}
Loading

0 comments on commit 0d13fdd

Please sign in to comment.