@Test public void testLiteral() throws RepositoryException { QueryObjectModelFactory delegate = mock(QueryObjectModelFactory.class); QueryObjectModelFactoryFacade<Session> facade = getFacade(delegate); final Literal value = mock(Literal.class); final Value arg1 = mock(Value.class); when(delegate.literal(arg1)).thenReturn(value); assertSame("is same value", value, facade.literal(arg1)); }
@Override public Literal literal(final Value literalValue) throws RepositoryException { return delegate.literal(literalValue); }
QueryObjectModelFactoryFacade implements QueryObjectModelFactory { @Override public Literal literal(final Value literalValue) throws RepositoryException { return delegate.literal(literalValue); } }
QueryObjectModelFactoryFacade implements QueryObjectModelFactory { @Override public Literal literal(final Value literalValue) throws RepositoryException { return delegate.literal(literalValue); } QueryObjectModelFactoryFacade(@NotNull final QueryObjectModelFactory delegate, @NotNull final SessionFacade<S> session); }
QueryObjectModelFactoryFacade implements QueryObjectModelFactory { @Override public Literal literal(final Value literalValue) throws RepositoryException { return delegate.literal(literalValue); } QueryObjectModelFactoryFacade(@NotNull final QueryObjectModelFactory delegate, @NotNull final SessionFacade<S> session); @Override QueryObjectModel createQuery(final Source source,
                                        final Constraint constraint,
                                        final Ordering[] orderings,
                                        final Column[] columns); @Override Selector selector(final String nodeTypeName, final String selectorName); @Override Join join(final Source left, final Source right, final String joinType, final JoinCondition joinCondition); @Override EquiJoinCondition equiJoinCondition(final String selector1Name,
                                               final String property1Name,
                                               final String selector2Name,
                                               final String property2Name); @Override SameNodeJoinCondition sameNodeJoinCondition(final String selector1Name, final String selector2Name, final String selector2Path); @Override ChildNodeJoinCondition childNodeJoinCondition(final String childSelectorName, final String parentSelectorName); @Override DescendantNodeJoinCondition descendantNodeJoinCondition(final String descendantSelectorName, final String ancestorSelectorName); @Override And and(final Constraint constraint1, final Constraint constraint2); @Override Or or(final Constraint constraint1, final Constraint constraint2); @Override Not not(final Constraint constraint); @Override Comparison comparison(final DynamicOperand operand1, final String operator, final StaticOperand operand2); @Override PropertyExistence propertyExistence(final String selectorName, final String propertyName); @Override FullTextSearch fullTextSearch(final String selectorName, final String propertyName, final StaticOperand fullTextSearchExpression); @Override SameNode sameNode(final String selectorName, final String path); @Override ChildNode childNode(final String selectorName, final String path); @Override DescendantNode descendantNode(final String selectorName, final String path); @Override PropertyValue propertyValue(final String selectorName, final String propertyName); @Override Length length(final PropertyValue propertyValue); @Override NodeName nodeName(final String selectorName); @Override NodeLocalName nodeLocalName(final String selectorName); @Override FullTextSearchScore fullTextSearchScore(final String selectorName); @Override LowerCase lowerCase(final DynamicOperand operand); @Override UpperCase upperCase(final DynamicOperand operand); @Override BindVariableValue bindVariable(final String bindVariableName); @Override Literal literal(final Value literalValue); @Override Ordering ascending(final DynamicOperand operand); @Override Ordering descending(final DynamicOperand operand); @Override Column column(final String selectorName, final String propertyName, final String columnName); }
QueryObjectModelFactoryFacade implements QueryObjectModelFactory { @Override public Literal literal(final Value literalValue) throws RepositoryException { return delegate.literal(literalValue); } QueryObjectModelFactoryFacade(@NotNull final QueryObjectModelFactory delegate, @NotNull final SessionFacade<S> session); @Override QueryObjectModel createQuery(final Source source,
                                        final Constraint constraint,
                                        final Ordering[] orderings,
                                        final Column[] columns); @Override Selector selector(final String nodeTypeName, final String selectorName); @Override Join join(final Source left, final Source right, final String joinType, final JoinCondition joinCondition); @Override EquiJoinCondition equiJoinCondition(final String selector1Name,
                                               final String property1Name,
                                               final String selector2Name,
                                               final String property2Name); @Override SameNodeJoinCondition sameNodeJoinCondition(final String selector1Name, final String selector2Name, final String selector2Path); @Override ChildNodeJoinCondition childNodeJoinCondition(final String childSelectorName, final String parentSelectorName); @Override DescendantNodeJoinCondition descendantNodeJoinCondition(final String descendantSelectorName, final String ancestorSelectorName); @Override And and(final Constraint constraint1, final Constraint constraint2); @Override Or or(final Constraint constraint1, final Constraint constraint2); @Override Not not(final Constraint constraint); @Override Comparison comparison(final DynamicOperand operand1, final String operator, final StaticOperand operand2); @Override PropertyExistence propertyExistence(final String selectorName, final String propertyName); @Override FullTextSearch fullTextSearch(final String selectorName, final String propertyName, final StaticOperand fullTextSearchExpression); @Override SameNode sameNode(final String selectorName, final String path); @Override ChildNode childNode(final String selectorName, final String path); @Override DescendantNode descendantNode(final String selectorName, final String path); @Override PropertyValue propertyValue(final String selectorName, final String propertyName); @Override Length length(final PropertyValue propertyValue); @Override NodeName nodeName(final String selectorName); @Override NodeLocalName nodeLocalName(final String selectorName); @Override FullTextSearchScore fullTextSearchScore(final String selectorName); @Override LowerCase lowerCase(final DynamicOperand operand); @Override UpperCase upperCase(final DynamicOperand operand); @Override BindVariableValue bindVariable(final String bindVariableName); @Override Literal literal(final Value literalValue); @Override Ordering ascending(final DynamicOperand operand); @Override Ordering descending(final DynamicOperand operand); @Override Column column(final String selectorName, final String propertyName, final String columnName);  }