Package org.apache.jackrabbit.spi.commons.query.qom

Examples of org.apache.jackrabbit.spi.commons.query.qom.PropertyValueImpl


                staticValue.getLong();
            } catch (ValueFormatException e) {
                throw new InvalidQueryException("Static value " +
                        staticValue.toString() + " cannot be converted to a Long");
            }
            PropertyValueImpl propValue = (PropertyValueImpl) node.getPropertyValue();
            return new LengthOperand((PropertyValueOperand) propValue.accept(this, null));
        }
View Full Code Here


        if (version.getVersion() < IndexFormatVersion.V3.getVersion()) {
            throw new InvalidQueryException("Length operator is only " +
                    "available with index version >= 3. Please re-index " +
                    "repository and execute query again.");
        }
        PropertyValueImpl pv = (PropertyValueImpl) node.getPropertyValue();
        String propName = npResolver.getJCRName(pv.getPropertyQName());
        if (data instanceof ComparisonImpl) {
            ComparisonImpl comp = (ComparisonImpl) data;
            int operator = comp.getOperator();
            Value v = (Value) ((StaticOperandImpl) comp.getOperand2()).accept(this, data);
            String namedLength = FieldNames.createNamedLength(propName, v.getLong());
View Full Code Here

                staticValue.getLong();
            } catch (ValueFormatException e) {
                throw new InvalidQueryException("Static value " +
                        staticValue.getString() + " cannot be converted to a Long");
            }
            PropertyValueImpl propValue = (PropertyValueImpl) node.getPropertyValue();
            return new LengthOperand((PropertyValueOperand) propValue.accept(this, null));
        }
View Full Code Here

                staticValue.getLong();
            } catch (ValueFormatException e) {
                throw new InvalidQueryException("Static value " +
                        staticValue.getString() + " cannot be converted to a Long");
            }
            PropertyValueImpl propValue = (PropertyValueImpl) node.getPropertyValue();
            return new LengthOperand((PropertyValueOperand) propValue.accept(this, null));
        }
View Full Code Here

            throws RepositoryException {
        final Name[] selectorName = new Name[1];
        QOMTreeVisitor visitor = new DefaultTraversingQOMTreeVisitor() {

            public Object visit(LengthImpl node, Object data) throws Exception {
                PropertyValueImpl propValue = (PropertyValueImpl) node.getPropertyValue();
                selectorName[0] = propValue.getSelectorQName();
                return new SortField(propValue.getPropertyQName().toString(),
                        new LengthSortComparator(nsMappings),
                        !ordering.isAscending());
            }

            public Object visit(LowerCaseImpl node, Object data)
View Full Code Here

                staticValue.getLong();
            } catch (ValueFormatException e) {
                throw new InvalidQueryException("Static value " +
                        staticValue.toString() + " cannot be converted to a Long");
            }
            PropertyValueImpl propValue = (PropertyValueImpl) node.getPropertyValue();
            return new LengthOperand((PropertyValueOperand) propValue.accept(this, null));
        }
View Full Code Here

            throws RepositoryException {
        final Name[] selectorName = new Name[1];
        QOMTreeVisitor visitor = new DefaultTraversingQOMTreeVisitor() {

            public Object visit(LengthImpl node, Object data) throws Exception {
                PropertyValueImpl propValue = (PropertyValueImpl) node.getPropertyValue();
                selectorName[0] = propValue.getSelectorQName();
                return new SortField(propValue.getPropertyQName().toString(),
                        new LengthSortComparator(nsMappings),
                        !ordering.isAscending());
            }

            public Object visit(LowerCaseImpl node, Object data)
View Full Code Here

                staticValue.getLong();
            } catch (ValueFormatException e) {
                throw new InvalidQueryException("Static value " +
                        staticValue.getString() + " cannot be converted to a Long");
            }
            PropertyValueImpl propValue = (PropertyValueImpl) node.getPropertyValue();
            return new LengthOperand((PropertyValueOperand) propValue.accept(this, null));
        }
View Full Code Here

                staticValue.getLong();
            } catch (ValueFormatException e) {
                throw new InvalidQueryException("Static value " +
                        staticValue.toString() + " cannot be converted to a Long");
            }
            PropertyValueImpl propValue = (PropertyValueImpl) node.getPropertyValue();
            return new LengthOperand((PropertyValueOperand) propValue.accept(this, null));
        }
View Full Code Here

TOP

Related Classes of org.apache.jackrabbit.spi.commons.query.qom.PropertyValueImpl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.