test_class.declarator: IS_BLUE = new SimpleAttribute<Car, Boolean>("is_blue") {
          @Override
          public Boolean getValue(Car object, QueryOptions queryOptions) {
              return object.getColor().equals(Car.Color.BLUE);
          }
      }
test_class.modifier: static final
test_class.original_string: static final Attribute<Car, Boolean> IS_BLUE = new SimpleAttribute<Car, Boolean>("is_blue") {
          @Override
          public Boolean getValue(Car object, QueryOptions queryOptions) {
              return object.getColor().equals(Car.Color.BLUE);
          }
      };
test_class.type: Attribute<Car, Boolean>
test_class.var_name: IS_BLUE
test_class.declarator: parser = new SQLParser<Car>(Car.class){{
          registerAttribute(Car.CAR_ID);
          registerAttribute(Car.MANUFACTURER);
          registerAttribute(Car.MODEL);
          registerAttribute(Car.COLOR);
          registerAttribute(Car.DOORS);
          registerAttribute(Car.PRICE);
          registerAttribute(Car.FEATURES);
          registerAttribute(IS_BLUE);
      }}
test_class.modifier: final
test_class.original_string: final SQLParser<Car> parser = new SQLParser<Car>(Car.class){{
          registerAttribute(Car.CAR_ID);
          registerAttribute(Car.MANUFACTURER);
          registerAttribute(Car.MODEL);
          registerAttribute(Car.COLOR);
          registerAttribute(Car.DOORS);
          registerAttribute(Car.PRICE);
          registerAttribute(Car.FEATURES);
          registerAttribute(IS_BLUE);
      }};
test_class.type: SQLParser<Car>
test_class.var_name: parser
test_class.file: code/src/test/java/com/googlecode/cqengine/query/parser/sql/SQLParserTest.java
test_class.identifier: SQLParserTest
test_case.body: @Test
      public void testOrderBy_SimpleOrdering1() {
          ParseResult<Car> parseResult = parser.parse("SELECT * FROM cars WHERE 'manufacturer' = 'Ford' ORDER BY manufacturer ASC");
          assertQueriesEquals(equal(Car.MANUFACTURER, "Ford"), parseResult.getQuery());
          Assert.assertEquals(queryOptions(orderBy(ascending(Car.MANUFACTURER))), parseResult.getQueryOptions());
      }
test_case.class_method_signature: SQLParserTest.testOrderBy_SimpleOrdering1()
test_case.full_signature: @Test public void testOrderBy_SimpleOrdering1()
test_case.identifier: testOrderBy_SimpleOrdering1
test_case.invocations: parse assertQueriesEquals equal getQuery assertEquals queryOptions orderBy ascending getQueryOptions
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testOrderBy_SimpleOrdering1()
focal_class.file: code/src/main/java/com/googlecode/cqengine/query/parser/sql/SQLParser.java
focal_class.identifier: SQLParser
focal_class.class_method_signature: SQLParser.SQLParser(Class<O> objectType)
focal_class.full_signature: public  SQLParser(Class<O> objectType)
focal_class.identifier: SQLParser
focal_class.modifiers: public
focal_class.parameters: (Class<O> objectType)
focal_class.signature:  SQLParser(Class<O> objectType)
focal_class.class_method_signature: SQLParser.parse(String query)
focal_class.full_signature: @Override public ParseResult<O> parse(String query)
focal_class.identifier: parse
focal_class.modifiers: @Override public
focal_class.parameters: (String query)
focal_class.return: ParseResult<O>
focal_class.signature: ParseResult<O> parse(String query)
focal_class.class_method_signature: SQLParser.forPojo(Class<O> pojoClass)
focal_class.full_signature: public static SQLParser<O> forPojo(Class<O> pojoClass)
focal_class.identifier: forPojo
focal_class.modifiers: public static
focal_class.parameters: (Class<O> pojoClass)
focal_class.return: SQLParser<O>
focal_class.signature: SQLParser<O> forPojo(Class<O> pojoClass)
focal_class.class_method_signature: SQLParser.forPojoWithAttributes(Class<O> pojoClass, Map<String, ? extends Attribute<O, ?>> attributes)
focal_class.full_signature: public static SQLParser<O> forPojoWithAttributes(Class<O> pojoClass, Map<String, ? extends Attribute<O, ?>> attributes)
focal_class.identifier: forPojoWithAttributes
focal_class.modifiers: public static
focal_class.parameters: (Class<O> pojoClass, Map<String, ? extends Attribute<O, ?>> attributes)
focal_class.return: SQLParser<O>
focal_class.signature: SQLParser<O> forPojoWithAttributes(Class<O> pojoClass, Map<String, ? extends Attribute<O, ?>> attributes)
focal_class.superclass: extends QueryParser<O>
focal_method.body: @Override
      public ParseResult<O> parse(String query) {
          try {
              if (query == null) {
                  throw new IllegalArgumentException("Query was null");
              }
              SQLGrammarLexer lexer = new SQLGrammarLexer(new ANTLRInputStream(query));
              lexer.removeErrorListeners();
              lexer.addErrorListener(SYNTAX_ERROR_LISTENER);
  
              CommonTokenStream tokens = new CommonTokenStream(lexer);
  
              SQLGrammarParser parser = new SQLGrammarParser(tokens);
              parser.removeErrorListeners();
              parser.addErrorListener(SYNTAX_ERROR_LISTENER);
  
              SQLGrammarParser.StartContext queryContext = parser.start();
  
              ParseTreeWalker walker = new ParseTreeWalker();
              SQLAntlrListener<O> listener = new SQLAntlrListener<O>(this);
              walker.walk(listener, queryContext);
              return new ParseResult<O>(listener.getParsedQuery(), listener.getQueryOptions());
          }
          catch (InvalidQueryException e) {
              throw e;
          }
          catch (Exception e) {
              throw new InvalidQueryException("Failed to parse query", e);
          }
      }
focal_method.class_method_signature: SQLParser.parse(String query)
focal_method.full_signature: @Override public ParseResult<O> parse(String query)
focal_method.identifier: parse
focal_method.invocations: removeErrorListeners addErrorListener removeErrorListeners addErrorListener start walk getParsedQuery getQueryOptions
focal_method.modifiers: @Override public
focal_method.parameters: (String query)
focal_method.return: ParseResult<O>
focal_method.signature: ParseResult<O> parse(String query)