- From: Yves Lafon via cvs-syncmail <cvsmail@w3.org>
- Date: Fri, 28 Sep 2012 08:32:02 +0000
- To: www-validator-cvs@w3.org
Update of /sources/public/2002/css-validator/org/w3c/css/properties/css1
In directory hutz:/tmp/cvs-serv711/css1
Modified Files:
CssBorderBottom.java CssBorderLeft.java CssBorderRight.java
CssBorderTop.java
Log Message:
NPE issue
Index: CssBorderBottom.java
===================================================================
RCS file: /sources/public/2002/css-validator/org/w3c/css/properties/css1/CssBorderBottom.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- CssBorderBottom.java 3 May 2012 13:21:02 -0000 1.9
+++ CssBorderBottom.java 28 Sep 2012 08:32:00 -0000 1.10
@@ -19,52 +19,52 @@
*/
public class CssBorderBottom extends org.w3c.css.properties.css.CssBorderBottom {
- /**
- * Create a new CssBorderBottom
- */
- public CssBorderBottom() {
- }
+ /**
+ * Create a new CssBorderBottom
+ */
+ public CssBorderBottom() {
+ }
- /**
- * Set the value of the property<br/>
- * Does not check the number of values
- *
- * @param expression The expression for this property
- * @throws org.w3c.css.util.InvalidParamException
- * The expression is incorrect
- */
- public CssBorderBottom(ApplContext ac, CssExpression expression)
- throws InvalidParamException {
- this(ac, expression, false);
- }
+ /**
+ * Set the value of the property<br/>
+ * Does not check the number of values
+ *
+ * @param expression The expression for this property
+ * @throws org.w3c.css.util.InvalidParamException
+ * The expression is incorrect
+ */
+ public CssBorderBottom(ApplContext ac, CssExpression expression)
+ throws InvalidParamException {
+ this(ac, expression, false);
+ }
- /**
- * Set the value of the property
- *
- * @param expression The expression for this property
- * @param check set it to true to check the number of values
- * @throws org.w3c.css.util.InvalidParamException
- * The expression is incorrect
- */
- public CssBorderBottom(ApplContext ac, CssExpression expression,
- boolean check) throws InvalidParamException {
- CssBorder.SideValues values = CssBorder.checkBorderSide(ac, this, expression, check);
- if (values.width != null) {
- _width = new CssBorderBottomWidth();
- _width.setByUser();
- _width.value = values.width;
- }
- if (values.style != null) {
- _style = new CssBorderBottomStyle();
- _style.setByUser();
- _style.value = values.style;
- }
- if (values.color != null) {
- _color = new CssBorderBottomColor();
- _color.setByUser();
- _color.value = values.color;
- }
- }
+ /**
+ * Set the value of the property
+ *
+ * @param expression The expression for this property
+ * @param check set it to true to check the number of values
+ * @throws org.w3c.css.util.InvalidParamException
+ * The expression is incorrect
+ */
+ public CssBorderBottom(ApplContext ac, CssExpression expression,
+ boolean check) throws InvalidParamException {
+ CssBorder.SideValues values = CssBorder.checkBorderSide(ac, this, expression, check);
+ if (values.width != null) {
+ _width = new CssBorderBottomWidth();
+ _width.setByUser();
+ _width.value = values.width;
+ }
+ if (values.style != null) {
+ _style = new CssBorderBottomStyle();
+ _style.setByUser();
+ _style.value = values.style;
+ }
+ if (values.color != null) {
+ _color = new CssBorderBottomColor();
+ _color.setByUser();
+ _color.value = values.color;
+ }
+ }
/**
* Add this property to the CssStyle
@@ -81,43 +81,48 @@
if (_width != null) {
_width.addToStyle(ac, style);
}
- if (css1Style.cssBorder.borderColor.bottom != null) {
- style.addRedefinitionWarning(ac, _color);
+ if (_color != null) {
+ if (css1Style.cssBorder.borderColor.bottom != null) {
+ style.addRedefinitionWarning(ac, _color);
+ }
+ css1Style.cssBorder.borderColor.bottom = _color;
}
- css1Style.cssBorder.borderColor.bottom = _color;
- if (css1Style.cssBorder.borderStyle.bottom != null) {
- style.addRedefinitionWarning(ac, _style);
+ if (_style != null) {
+ if (css1Style.cssBorder.borderStyle.bottom != null) {
+ style.addRedefinitionWarning(ac, _style);
+ }
+ css1Style.cssBorder.borderStyle.bottom = _style;
}
- css1Style.cssBorder.borderStyle.bottom = _style;
}
- /**
- * Returns a string representation of the object.
- */
- public String toString() {
- if (_width != null && inherit == _width.value) {
- return inherit.toString();
- }
- StringBuilder sb = new StringBuilder();
- boolean first = true;
- if (_width != null) {
- sb.append(_width);
- first = false;
- }
- if (_style != null) {
- if (first) {
- sb.append(_style);
- } else {
- sb.append(' ').append(_style);
- }
- first = false;
- }
- if (_color != null) {
- if (first) {
- sb.append(_color);
- } else {
- sb.append(' ').append(_color);
- }
- }
- return sb.toString();
- }
+
+ /**
+ * Returns a string representation of the object.
+ */
+ public String toString() {
+ if (_width != null && inherit == _width.value) {
+ return inherit.toString();
+ }
+ StringBuilder sb = new StringBuilder();
+ boolean first = true;
+ if (_width != null) {
+ sb.append(_width);
+ first = false;
+ }
+ if (_style != null) {
+ if (first) {
+ sb.append(_style);
+ } else {
+ sb.append(' ').append(_style);
+ }
+ first = false;
+ }
+ if (_color != null) {
+ if (first) {
+ sb.append(_color);
+ } else {
+ sb.append(' ').append(_color);
+ }
+ }
+ return sb.toString();
+ }
}
Index: CssBorderRight.java
===================================================================
RCS file: /sources/public/2002/css-validator/org/w3c/css/properties/css1/CssBorderRight.java,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- CssBorderRight.java 3 May 2012 13:21:03 -0000 1.8
+++ CssBorderRight.java 28 Sep 2012 08:32:00 -0000 1.9
@@ -19,50 +19,52 @@
*/
public class CssBorderRight extends org.w3c.css.properties.css.CssBorderRight {
- /**
- * Create a new CssBorderRight
- */
- public CssBorderRight() {
- }
+ /**
+ * Create a new CssBorderRight
+ */
+ public CssBorderRight() {
+ }
- /**
- * Set the value of the property<br/>
- * Does not check the number of values
- *
- * @param expression The expression for this property
- * @throws org.w3c.css.util.InvalidParamException The expression is incorrect
- */
- public CssBorderRight(ApplContext ac, CssExpression expression)
- throws InvalidParamException {
- this(ac, expression, false);
- }
+ /**
+ * Set the value of the property<br/>
+ * Does not check the number of values
+ *
+ * @param expression The expression for this property
+ * @throws org.w3c.css.util.InvalidParamException
+ * The expression is incorrect
+ */
+ public CssBorderRight(ApplContext ac, CssExpression expression)
+ throws InvalidParamException {
+ this(ac, expression, false);
+ }
- /**
- * Set the value of the property
- *
- * @param expression The expression for this property
- * @param check set it to true to check the number of values
- * @throws org.w3c.css.util.InvalidParamException The expression is incorrect
- */
- public CssBorderRight(ApplContext ac, CssExpression expression,
- boolean check) throws InvalidParamException {
- CssBorder.SideValues values = CssBorder.checkBorderSide(ac, this, expression, check);
- if (values.width != null) {
- _width = new CssBorderRightWidth();
- _width.setByUser();
- _width.value = values.width;
- }
- if (values.style != null) {
- _style = new CssBorderRightStyle();
- _style.setByUser();
- _style.value = values.style;
- }
- if (values.color != null) {
- _color = new CssBorderRightColor();
- _color.setByUser();
- _color.value = values.color;
- }
- }
+ /**
+ * Set the value of the property
+ *
+ * @param expression The expression for this property
+ * @param check set it to true to check the number of values
+ * @throws org.w3c.css.util.InvalidParamException
+ * The expression is incorrect
+ */
+ public CssBorderRight(ApplContext ac, CssExpression expression,
+ boolean check) throws InvalidParamException {
+ CssBorder.SideValues values = CssBorder.checkBorderSide(ac, this, expression, check);
+ if (values.width != null) {
+ _width = new CssBorderRightWidth();
+ _width.setByUser();
+ _width.value = values.width;
+ }
+ if (values.style != null) {
+ _style = new CssBorderRightStyle();
+ _style.setByUser();
+ _style.value = values.style;
+ }
+ if (values.color != null) {
+ _color = new CssBorderRightColor();
+ _color.setByUser();
+ _color.value = values.color;
+ }
+ }
/**
* Add this property to the CssStyle
@@ -79,45 +81,50 @@
if (_width != null) {
_width.addToStyle(ac, style);
}
- if (css1Style.cssBorder.borderColor.right != null) {
- style.addRedefinitionWarning(ac, _color);
+ if (_color != null) {
+ if (css1Style.cssBorder.borderColor.right != null) {
+ style.addRedefinitionWarning(ac, _color);
+ css1Style.cssBorder.borderColor.right = _color;
+ }
}
- css1Style.cssBorder.borderColor.right = _color;
- if (css1Style.cssBorder.borderStyle.right != null) {
- style.addRedefinitionWarning(ac, _style);
+ if (_style != null) {
+ if (css1Style.cssBorder.borderStyle.right != null) {
+ style.addRedefinitionWarning(ac, _style);
+ }
+ css1Style.cssBorder.borderStyle.right = _style;
}
- css1Style.cssBorder.borderStyle.right = _style;
}
/**
- * Returns a string representation of the object.
- */
- public String toString() {
- if (_width != null && inherit == _width.value) {
- return inherit.toString();
- }
- StringBuilder sb = new StringBuilder();
- boolean first = true;
- if (_width != null) {
- sb.append(_width);
- first = false;
- }
- if (_style != null) {
- if (first) {
- sb.append(_style);
- } else {
- sb.append(' ').append(_style);
- }
- first = false;
- }
- if (_color != null) {
- if (first) {
- sb.append(_color);
- } else {
- sb.append(' ').append(_color);
- }
- }
- return sb.toString();
- }
+ * Returns a string representation of the object.
+ */
+
+ public String toString() {
+ if (_width != null && inherit == _width.value) {
+ return inherit.toString();
+ }
+ StringBuilder sb = new StringBuilder();
+ boolean first = true;
+ if (_width != null) {
+ sb.append(_width);
+ first = false;
+ }
+ if (_style != null) {
+ if (first) {
+ sb.append(_style);
+ } else {
+ sb.append(' ').append(_style);
+ }
+ first = false;
+ }
+ if (_color != null) {
+ if (first) {
+ sb.append(_color);
+ } else {
+ sb.append(' ').append(_color);
+ }
+ }
+ return sb.toString();
+ }
}
Index: CssBorderLeft.java
===================================================================
RCS file: /sources/public/2002/css-validator/org/w3c/css/properties/css1/CssBorderLeft.java,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- CssBorderLeft.java 3 May 2012 13:21:03 -0000 1.8
+++ CssBorderLeft.java 28 Sep 2012 08:32:00 -0000 1.9
@@ -19,50 +19,52 @@
public class CssBorderLeft extends org.w3c.css.properties.css.CssBorderLeft {
- /**
- * Create a new CssBorderLeft
- */
- public CssBorderLeft() {
- }
+ /**
+ * Create a new CssBorderLeft
+ */
+ public CssBorderLeft() {
+ }
- /**
- * Set the value of the property<br/>
- * Does not check the number of values
- *
- * @param expression The expression for this property
- * @throws org.w3c.css.util.InvalidParamException The expression is incorrect
- */
- public CssBorderLeft(ApplContext ac, CssExpression expression)
- throws InvalidParamException {
- this(ac, expression, false);
- }
+ /**
+ * Set the value of the property<br/>
+ * Does not check the number of values
+ *
+ * @param expression The expression for this property
+ * @throws org.w3c.css.util.InvalidParamException
+ * The expression is incorrect
+ */
+ public CssBorderLeft(ApplContext ac, CssExpression expression)
+ throws InvalidParamException {
+ this(ac, expression, false);
+ }
- /**
- * Set the value of the property
- *
- * @param expression The expression for this property
- * @param check set it to true to check the number of values
- * @throws org.w3c.css.util.InvalidParamException The expression is incorrect
- */
- public CssBorderLeft(ApplContext ac, CssExpression expression,
- boolean check) throws InvalidParamException {
- CssBorder.SideValues values = CssBorder.checkBorderSide(ac, this, expression, check);
- if (values.width != null) {
- _width = new CssBorderLeftWidth();
- _width.setByUser();
- _width.value = values.width;
- }
- if (values.style != null) {
- _style = new CssBorderLeftStyle();
- _style.setByUser();
- _style.value = values.style;
- }
- if (values.color != null) {
- _color = new CssBorderLeftColor();
- _color.setByUser();
- _color.value = values.color;
- }
- }
+ /**
+ * Set the value of the property
+ *
+ * @param expression The expression for this property
+ * @param check set it to true to check the number of values
+ * @throws org.w3c.css.util.InvalidParamException
+ * The expression is incorrect
+ */
+ public CssBorderLeft(ApplContext ac, CssExpression expression,
+ boolean check) throws InvalidParamException {
+ CssBorder.SideValues values = CssBorder.checkBorderSide(ac, this, expression, check);
+ if (values.width != null) {
+ _width = new CssBorderLeftWidth();
+ _width.setByUser();
+ _width.value = values.width;
+ }
+ if (values.style != null) {
+ _style = new CssBorderLeftStyle();
+ _style.setByUser();
+ _style.value = values.style;
+ }
+ if (values.color != null) {
+ _color = new CssBorderLeftColor();
+ _color.setByUser();
+ _color.value = values.color;
+ }
+ }
/**
* Add this property to the CssStyle
@@ -79,44 +81,48 @@
if (_width != null) {
_width.addToStyle(ac, style);
}
- if (css1Style.cssBorder.borderColor.left != null) {
- style.addRedefinitionWarning(ac, _color);
+ if (_color != null) {
+ if (css1Style.cssBorder.borderColor.left != null) {
+ style.addRedefinitionWarning(ac, _color);
+ }
+ css1Style.cssBorder.borderColor.left = _color;
}
- css1Style.cssBorder.borderColor.left = _color;
- if (css1Style.cssBorder.borderStyle.left != null) {
- style.addRedefinitionWarning(ac, _style);
+ if (_style != null) {
+ if (css1Style.cssBorder.borderStyle.left != null) {
+ style.addRedefinitionWarning(ac, _style);
+ }
+ css1Style.cssBorder.borderStyle.left = _style;
}
- css1Style.cssBorder.borderStyle.left = _style;
}
- /**
- * Returns a string representation of the object.
- */
- public String toString() {
- if (_width != null && inherit == _width.value) {
- return inherit.toString();
- }
- StringBuilder sb = new StringBuilder();
- boolean first = true;
- if (_width != null) {
- sb.append(_width);
- first = false;
- }
- if (_style != null) {
- if (first) {
- sb.append(_style);
- } else {
- sb.append(' ').append(_style);
- }
- first = false;
- }
- if (_color != null) {
- if (first) {
- sb.append(_color);
- } else {
- sb.append(' ').append(_color);
- }
- }
- return sb.toString();
- }
+ /**
+ * Returns a string representation of the object.
+ */
+ public String toString() {
+ if (_width != null && inherit == _width.value) {
+ return inherit.toString();
+ }
+ StringBuilder sb = new StringBuilder();
+ boolean first = true;
+ if (_width != null) {
+ sb.append(_width);
+ first = false;
+ }
+ if (_style != null) {
+ if (first) {
+ sb.append(_style);
+ } else {
+ sb.append(' ').append(_style);
+ }
+ first = false;
+ }
+ if (_color != null) {
+ if (first) {
+ sb.append(_color);
+ } else {
+ sb.append(' ').append(_color);
+ }
+ }
+ return sb.toString();
+ }
}
Index: CssBorderTop.java
===================================================================
RCS file: /sources/public/2002/css-validator/org/w3c/css/properties/css1/CssBorderTop.java,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- CssBorderTop.java 3 May 2012 13:21:04 -0000 1.8
+++ CssBorderTop.java 28 Sep 2012 08:32:00 -0000 1.9
@@ -19,50 +19,52 @@
*/
public class CssBorderTop extends org.w3c.css.properties.css.CssBorderTop {
- /**
- * Create a new CssBorderTop
- */
- public CssBorderTop() {
- }
+ /**
+ * Create a new CssBorderTop
+ */
+ public CssBorderTop() {
+ }
- /**
- * Set the value of the property<br/>
- * Does not check the number of values
- *
- * @param expression The expression for this property
- * @throws org.w3c.css.util.InvalidParamException The expression is incorrect
- */
- public CssBorderTop(ApplContext ac, CssExpression expression)
- throws InvalidParamException {
- this(ac, expression, false);
- }
+ /**
+ * Set the value of the property<br/>
+ * Does not check the number of values
+ *
+ * @param expression The expression for this property
+ * @throws org.w3c.css.util.InvalidParamException
+ * The expression is incorrect
+ */
+ public CssBorderTop(ApplContext ac, CssExpression expression)
+ throws InvalidParamException {
+ this(ac, expression, false);
+ }
- /**
- * Set the value of the property
- *
- * @param expression The expression for this property
- * @param check set it to true to check the number of values
- * @throws org.w3c.css.util.InvalidParamException The expression is incorrect
- */
- public CssBorderTop(ApplContext ac, CssExpression expression,
- boolean check) throws InvalidParamException {
- CssBorder.SideValues values = CssBorder.checkBorderSide(ac, this, expression, check);
- if (values.width != null) {
- _width = new CssBorderTopWidth();
- _width.setByUser();
- _width.value = values.width;
- }
- if (values.style != null) {
- _style = new CssBorderTopStyle();
- _style.setByUser();
- _style.value = values.style;
- }
- if (values.color != null) {
- _color = new CssBorderTopColor();
- _color.setByUser();
- _color.value = values.color;
- }
- }
+ /**
+ * Set the value of the property
+ *
+ * @param expression The expression for this property
+ * @param check set it to true to check the number of values
+ * @throws org.w3c.css.util.InvalidParamException
+ * The expression is incorrect
+ */
+ public CssBorderTop(ApplContext ac, CssExpression expression,
+ boolean check) throws InvalidParamException {
+ CssBorder.SideValues values = CssBorder.checkBorderSide(ac, this, expression, check);
+ if (values.width != null) {
+ _width = new CssBorderTopWidth();
+ _width.setByUser();
+ _width.value = values.width;
+ }
+ if (values.style != null) {
+ _style = new CssBorderTopStyle();
+ _style.setByUser();
+ _style.value = values.style;
+ }
+ if (values.color != null) {
+ _color = new CssBorderTopColor();
+ _color.setByUser();
+ _color.value = values.color;
+ }
+ }
/**
* Add this property to the CssStyle
@@ -79,45 +81,49 @@
if (_width != null) {
_width.addToStyle(ac, style);
}
- if (css1Style.cssBorder.borderColor.top != null) {
- style.addRedefinitionWarning(ac, _color);
+ if (_color != null) {
+ if (css1Style.cssBorder.borderColor.top != null) {
+ style.addRedefinitionWarning(ac, _color);
+ }
+ css1Style.cssBorder.borderColor.top = _color;
}
- css1Style.cssBorder.borderColor.top = _color;
- if (css1Style.cssBorder.borderStyle.top != null) {
- style.addRedefinitionWarning(ac, _style);
+ if (_style != null) {
+ if (css1Style.cssBorder.borderStyle.top != null) {
+ style.addRedefinitionWarning(ac, _style);
+ }
+ css1Style.cssBorder.borderStyle.top = _style;
}
- css1Style.cssBorder.borderStyle.top = _style;
}
/**
- * Returns a string representation of the object.
- */
- public String toString() {
- if (_width != null && inherit == _width.value) {
- return inherit.toString();
- }
- StringBuilder sb = new StringBuilder();
- boolean first = true;
- if (_width != null) {
- sb.append(_width);
- first = false;
- }
- if (_style != null) {
- if (first) {
- sb.append(_style);
- } else {
- sb.append(' ').append(_style);
- }
- first = false;
- }
- if (_color != null) {
- if (first) {
- sb.append(_color);
- } else {
- sb.append(' ').append(_color);
- }
- }
- return sb.toString();
- }
+ * Returns a string representation of the object.
+ */
+ public String toString() {
+ if (_width != null && inherit == _width.value) {
+ return inherit.toString();
+ }
+ StringBuilder sb = new StringBuilder();
+ boolean first = true;
+ if (_width != null) {
+ sb.append(_width);
+ first = false;
+ }
+ if (_style != null) {
+ if (first) {
+ sb.append(_style);
+ } else {
+ sb.append(' ').append(_style);
+ }
+ first = false;
+ }
+ if (_color != null) {
+ if (first) {
+ sb.append(_color);
+ } else {
+ sb.append(' ').append(_color);
+ }
+ }
+ return sb.toString();
+ }
}
Received on Friday, 28 September 2012 08:32:17 UTC