/*
- * Jalview - A Sequence Alignment Editor and Viewer (Version 2.8.2)
- * Copyright (C) 2014 The Jalview Authors
+ * Jalview - A Sequence Alignment Editor and Viewer ($$Version-Rel$$)
+ * Copyright (C) $$Year-Rel$$ The Jalview Authors
*
* This file is part of Jalview.
*
static Hashtable<Integer, Integer> pairHash = new Hashtable();
- private static final Character[] openingPars =
- { '(', '[', '{', '<', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J',
- 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X',
- 'Y', 'Z' };
+ private static final Character[] openingPars = { '(', '[', '{', '<', 'A',
+ 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O',
+ 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z' };
- private static final Character[] closingPars =
- { ')', ']', '}', '>', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j',
- 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x',
- 'y', 'z' };
+ private static final Character[] closingPars = { ')', ']', '}', '>', 'a',
+ 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o',
+ 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z' };
private static HashSet<Character> openingParsSet = new HashSet<Character>(
Arrays.asList(openingPars));
{
if (!isClosingParenthesis(closingParenthesis))
{
- throw new WUSSParseException(MessageManager.formatMessage("exception.querying_matching_opening_parenthesis_for_non_closing_parenthesis", new String[]{new StringBuffer(closingParenthesis).toString()}), -1);
+ throw new WUSSParseException(
+ MessageManager.formatMessage(
+ "exception.querying_matching_opening_parenthesis_for_non_closing_parenthesis",
+ new String[] { new StringBuffer(closingParenthesis)
+ .toString() }), -1);
}
return closingToOpening.get(closingParenthesis);
if (!stacks.containsKey(opening))
{
- throw new WUSSParseException(MessageManager.formatMessage("exception.mismatched_unseen_closing_char", new String[]{new StringBuffer(base).toString()}), i);
+ throw new WUSSParseException(MessageManager.formatMessage(
+ "exception.mismatched_unseen_closing_char",
+ new String[] { new StringBuffer(base).toString() }), i);
}
Stack<Integer> stack = stacks.get(opening);
if (stack.isEmpty())
{
// error whilst parsing i'th position. pass back
- throw new WUSSParseException(MessageManager.formatMessage("exception.mismatched_closing_char", new String[]{new StringBuffer(base).toString()}), i);
+ throw new WUSSParseException(MessageManager.formatMessage(
+ "exception.mismatched_closing_char",
+ new String[] { new StringBuffer(base).toString() }), i);
}
int temp = stack.pop();
Stack<Integer> stack = stacks.get(opening);
if (!stack.empty())
{
- throw new WUSSParseException(MessageManager.formatMessage("exception.mismatched_opening_char", new String[]{new StringBuffer(opening).toString(),Integer.valueOf(stack.pop()).toString()}), i);
+ throw new WUSSParseException(MessageManager.formatMessage(
+ "exception.mismatched_opening_char",
+ new String[] { new StringBuffer(opening).toString(),
+ Integer.valueOf(stack.pop()).toString() }), i);
}
}
return pairs;