public Term stringLiteral ( ) throws SourceCodeException { Token valToken = consumeToken ( STRING_LITERAL ) ; String valWithQuotes = valToken . image ; StringLiteral result = new StringLiteral ( valWithQuotes . substring ( 1 , valWithQuotes . length ( ) - 1 ) ) ; // Set the position that the literal was parsed from. SourceCodePosition position = new SourceCodePositionImpl ( valToken . beginLine , valToken . beginColumn , valToken . endLine , valToken . endColumn ) ; result . setSourceCodePosition ( position ) ; return result ; }
Parses a string literal .