{
throw new MalformedUriTemplateException("Expression close brace was found at position " + position
+ " yet there was no start brace.", position);
}
expressionCaptureOn = false;
components.add(new Expression(buffer.toString(), this.startPosition));
buffer = null;
}
else
{
throw new IllegalStateException("Cannot end an expression without beginning the template");