Package org.foray.fotree.value

Examples of org.foray.fotree.value.PropertyValue


     * @return The parsed, storable property value.
     * @throws PropertyException For an invalid property value.
     */
    private PropertyValue createPropertyValue(final String value,
            final FObj fobj) throws PropertyException {
        final PropertyValue pv = this.standardParse(fobj, value);
        if (pv.canEvalKeyword()) {
            return pv;
        }

        /* Tokenize the value and loop through the tokens, adjusting the
         * TextDecoDT instance accordingly.
View Full Code Here


     * @return The parsed, storable property value.
     * @throws PropertyException For an invalid property value.
     */
    private PropertyValue createPropertyValue(final FObj fobj,
            final String value) throws PropertyException {
        final PropertyValue pv = standardParse(fobj, value);
        if (DtBorderWidth.isBorderWidth(pv)) {
            return pv;
        }
        if (this.isKeywordInherit(pv)) {
            return pv;
View Full Code Here

     * @return The parsed, storable property value.
     * @throws PropertyException For an invalid property value.
     */
    private PropertyValue createPropertyValue(final FObj fobj,
            final String value) throws PropertyException {
        final PropertyValue pv = standardParse(fobj, value);
        if (pv.canEvalNumeric()) {
            return pv;
        }
        throw unexpectedValue(value, fobj);
    }
View Full Code Here

     * @return The parsed, storable property value.
     * @throws PropertyException For an invalid property value.
     */
    private PropertyValue createPropertyValue(final FObj fobj,
            final String value) throws PropertyException {
        PropertyValue pv = standardParse(fobj, value);
        if (pv.canEvalKeyword()) {
            return pv;
        }
        pv = parseTokens(fobj, value);
        if (pv != null) {
            return pv;
View Full Code Here

        if (tokenizer.countTokens() < 1) {
            throw unexpectedValue(attributeValue, fobj);
        }
        while (tokenizer.hasMoreTokens()) {
            final String token = tokenizer.nextToken();
            final PropertyValue pv = parseToken(fobj, token);
            collection.addItem(pv);
        }
        return collection;
    }
View Full Code Here

     * @return The parsed, storable property for the token.
     * @throws PropertyException For an invalid property value.
     */
    private PropertyValue parseToken(final FObj fobj, final String token)
            throws PropertyException {
        final PropertyValue pv = this.standardParse(fobj, token,
                AbstractAllowedAxisScale.VALID_TOKEN_KEYWORDS);
        if (pv.canEvalKeyword()) {
            return pv;
        }
        if (pv.canEvalPercentage()) {
            return pv;
        }
        throw unexpectedValue(token, fobj);
    }
View Full Code Here

            return PdAllowedWidthScale.traitValueNoInstance(fobj);
        }
        final ValueCollection collection = (ValueCollection) this.value;
        final float[] returnValue = new float[collection.getCount()];
        for (int i = 0; i < collection.getCount(); i++) {
            final PropertyValue pv = collection.getItem(i);
            if (pv.canEvalKeyword()) {
                returnValue[i] = java.lang.Float.POSITIVE_INFINITY;
            } else if (pv.canEvalPercentage()) {
                returnValue[i] = pv.evalPercentage();
            }
        }
        return returnValue;
    }
View Full Code Here

     * @return The parsed, storable property value.
     * @throws PropertyException For an invalid property value.
     */
    private PropertyValue createPropertyValue(final FObj fobj,
            final String value) throws PropertyException {
        final PropertyValue pv = standardParse(fobj, value);
        if (pv.canEvalKeyword()) {
            return pv;
        }
        if (pv.canEvalPercentage()) {
            if (pv.evalPercentage() < 0) {
                throw unexpectedValue(value, fobj);
            }
            return pv;
        }
        if (pv.canEvalNumeric()) {
            /* This test includes both expressions that can and cannot evaluate
             * to a length, because <number> is one of the input values. */
            if (pv.evalNumeric() >= 0) {
                return pv;
            }
        }
        if (pv instanceof DtSpace) {
            return pv;
View Full Code Here

     * @return The parsed, storable property value.
     * @throws PropertyException For an invalid property value.
     */
    private PropertyValue createPropertyValue(final FObj fobj,
            final String value) throws PropertyException {
        final PropertyValue pv = standardParse(fobj, value);
        if (pv.canEvalKeyword()) {
            return pv;
        }
        throw unexpectedValue(value, fobj);
    }
View Full Code Here

     * @return The parsed, storable property value.
     * @throws PropertyException For an invalid property value.
     */
    private PropertyValue createPropertyValue(final FObj fobj,
            final String value) throws PropertyException {
        final PropertyValue pv = standardParse(fobj, value);
        if (pv.canEvalKeyword()) {
            return pv;
        }
        if (pv.canEvalLength()) {
            return pv;
        }
        if (pv.canEvalPercentage()) {
            return pv;
        }
        if (pv instanceof DtLengthConditional) {
            return pv;
        }
View Full Code Here

TOP

Related Classes of org.foray.fotree.value.PropertyValue

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.