Examples of IncrementObject


Examples of org.eclipse.jst.pagedesigner.css2.list.IncrementObject

  public List getCounter(CSSValue value) {
    if (value == null) {
      return null;
    }
    List result = new ArrayList();
    IncrementObject incrementObject = null;
    String identifier = null;
    Integer increment = null;
    ICSSNode cssValue = (ICSSNode) value;
    while (cssValue != null) {
      // find next idetifier.
      while (cssValue != null && !CounterHelper.isIdentifier(cssValue)) {
        cssValue = cssValue.getNextSibling();
      }
      if (cssValue == null) {
        return null;
      }
            // identifier:
            identifier = ((ICSSPrimitiveValue) value).getStringValue();
            cssValue = cssValue.getNextSibling();
            // value:
            if (CounterHelper.isNumber(cssValue)) {
              increment = new Integer((int) ((ICSSPrimitiveValue) value)
                  .getFloatValue(ICSSPrimitiveValue.CSS_INTEGER));
            }

      if (identifier != null) {
        incrementObject = new IncrementObject(identifier, increment);
        result.add(incrementObject);
      }
    }
    return result;
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.