final String propertyPath = lhs.getPropertyPath(); Set<String> temp = new HashSet<String>();
getCurrentFromClause(), dot.getLhs().getFromElement(), dot.getPropertyPath(), alias == null ? null : alias.getText(), null,
final String propertyPath = lhs.getPropertyPath(); Set temp = new HashSet();
final String propertyPath = lhs.getPropertyPath(); Set temp = new HashSet();
if (n instanceof DotNode) { DotNode dot = (DotNode) n; if (expression.equals(dot.getPropertyPath())) {
Bool.notEquals(Stmt.loadVariable("candidate").invoke("get", dotNode.getPropertyPath()).invoke("isNull"), null), Stmt.loadLiteral(null), Stmt.loadVariable("entityManager").invoke("find", Stmt.invokeStatic(Key.class, "fromJsonObject", Stmt.loadVariable("entityManager"), Stmt.loadVariable("candidate").invoke("get", dotNode.getPropertyPath()).invoke("isObject"), false), Stmt.loadStatic(Collections.class, "EMPTY_MAP"))); Stmt.loadVariable("candidate").invoke("get", dotNode.getPropertyPath()), requestedType);
@Override public Statement resolve(DotNode dotNode) { Class<?> lhsType = dotNode.getLhs().getDataType().getReturnedClass(); // ensure the attribute is available as a field of the comparator String attrVarName = dotNode.getPath().replace('.', '_') + "_attr"; if (containingClass != null && !generatedClassVariables.contains(attrVarName)) { generatedClassVariables.add(attrVarName); containingClass.privateField(attrVarName, ErraiAttribute.class) .modifiers(Modifier.Final) .initializesWith( Stmt.nestedCall(new StringStatement("entityManager.getMetamodel()", MetaClassFactory.get(ErraiMetamodel.class))) .invoke("entity", Stmt.loadLiteral(lhsType)) .invoke("getAttribute", dotNode.getPropertyPath())) .finish(); } // XXX need a StringStatement here because codegen can't see fields of anonymous inner classes. (ERRAI-363) return Stmt.nestedCall(new StringStatement(attrVarName, MetaClassFactory.get(ErraiAttribute.class))) .invoke("get", Stmt.loadVariable(variableName)); } }
getCurrentFromClause(), dot.getLhs().getFromElement(), dot.getPropertyPath(), alias == null ? null : alias.getText(), null,
getCurrentFromClause(), dot.getLhs().getFromElement(), dot.getPropertyPath(), alias == null ? null : alias.getText(), null,