W3C home > Mailing lists > Public > www-validator-cvs@w3.org > December 2012

CVS 2002/css-validator/org/w3c/css/properties/css

From: CVS User ylafon <cvsmail@w3.org>
Date: Fri, 07 Dec 2012 12:18:56 +0000
Message-Id: <E1TgwtM-0008Cw-CR@roscoe.w3.org>
To: www-validator-cvs@w3.org
Update of /sources/public/2002/css-validator/org/w3c/css/properties/css
In directory roscoe:/tmp/cvs-serv31496/css

Modified Files:
	CssBorderCollapse.java 
Added Files:
	CssSpeakHeader.java 
Log Message:
speak header per css2 (table) css21 (audio), and not in css3 (audio)

--- /sources/public/2002/css-validator/org/w3c/css/properties/css/CssBorderCollapse.java	2012/12/05 15:22:03	1.1
+++ /sources/public/2002/css-validator/org/w3c/css/properties/css/CssBorderCollapse.java	2012/12/07 12:18:56	1.2
@@ -1,8 +1,7 @@
+// $Id: CssBorderCollapse.java,v 1.2 2012/12/07 12:18:56 ylafon Exp $
+// Author: Yves Lafon <ylafon@w3.org>
 //
-// $Id: CssBorderCollapse.java,v 1.1 2012/12/05 15:22:03 ylafon Exp $
-// From Philippe Le Hegaret (Philippe.Le_Hegaret@sophia.inria.fr)
-//
-// (c) COPYRIGHT MIT and INRIA, 1997.
+// (c) COPYRIGHT MIT, ERCIM and Keio University, 2012.
 // Please first read the full copyright statement in file COPYRIGHT.html
 package org.w3c.css.properties.css;
 
@@ -15,7 +14,7 @@
 
 /**
  * @since CSS2
- * @version $Revision: 1.1 $
+ * @version $Revision: 1.2 $
  */
 public class CssBorderCollapse extends CssProperty {
 

--- /sources/public/2002/css-validator/org/w3c/css/properties/css/CssSpeakHeader.java	2012/12/07 12:18:56	NONE
+++ /sources/public/2002/css-validator/org/w3c/css/properties/css/CssSpeakHeader.java	2012/12/07 12:18:56	1.1
// $Id: CssSpeakHeader.java,v 1.1 2012/12/07 12:18:56 ylafon Exp $
// Author: Yves Lafon <ylafon@w3.org>
//
// (c) COPYRIGHT MIT, ERCIM and Keio University, 2012.
// Please first read the full copyright statement in file COPYRIGHT.html
package org.w3c.css.properties.css;

import org.w3c.css.parser.CssStyle;
import org.w3c.css.properties.css2.Css2Style;
import org.w3c.css.util.ApplContext;
import org.w3c.css.util.InvalidParamException;
import org.w3c.css.values.CssExpression;
import org.w3c.css.values.CssValue;

/**
 * @since CSS2
 * @version $Revision: 1.1 $
 */
public class CssSpeakHeader extends CssProperty {

    public CssValue value;

    /**
     * Create a new CssSpeakHeader
     */
    public CssSpeakHeader() {
    }

    /**
     * Creates a new CssSpeakHeader
     *
     * @param expression The expression for this property
     * @throws org.w3c.css.util.InvalidParamException
     *          Expressions are incorrect
     */
    public CssSpeakHeader(ApplContext ac, CssExpression expression, boolean check)
            throws InvalidParamException {
        throw new InvalidParamException("value",
                expression.getValue().toString(),
                getPropertyName(), ac);
    }

    public CssSpeakHeader(ApplContext ac, CssExpression expression)
            throws InvalidParamException {
        this(ac, expression, false);
    }

    /**
     * Returns the value of this property
     */
    public Object get() {
        return value;
    }


    /**
     * Returns the name of this property
     */
    public final String getPropertyName() {
        return "speak-header";
    }

    /**
     * Returns true if this property is "softly" inherited
     * e.g. his value is equals to inherit
     */
    public boolean isSoftlyInherited() {
        return value.equals(inherit);
    }

    /**
     * Returns a string representation of the object.
     */
    public String toString() {
        return value.toString();
    }

    /**
     * Add this property to the CssStyle.
     *
     * @param style The CssStyle
     */
    public void addToStyle(ApplContext ac, CssStyle style) {
        if (((Css2Style) style).cssSpeakHeader != null)
            style.addRedefinitionWarning(ac, this);
        ((Css2Style) style).cssSpeakHeader = this;
    }

    /**
     * Compares two properties for equality.
     *
     * @param property The other property.
     */
    public boolean equals(CssProperty property) {
        return (property instanceof CssSpeakHeader &&
                value.equals(((CssSpeakHeader) property).value));
    }


    /**
     * Get this property in the style.
     *
     * @param style   The style where the property is
     * @param resolve if true, resolve the style to find this property
     */
    public CssProperty getPropertyInStyle(CssStyle style, boolean resolve) {
        if (resolve) {
            return ((Css2Style) style).getSpeakHeader();
        } else {
            return ((Css2Style) style).cssSpeakHeader;
        }
    }
}
Received on Friday, 7 December 2012 12:19:00 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:17:54 UTC