Tabnine Logo
LiveAttributeException
Code IndexAdd Tabnine to your IDE (free)

How to use
LiveAttributeException
in
org.apache.batik.dom.svg

Best Java code snippets using org.apache.batik.dom.svg.LiveAttributeException (Showing top 20 results out of 315)

origin: org.apache.xmlgraphics/batik-anim

public void endNumberList() {
  if (count != 4) {
    throw new LiveAttributeException
      (element, localName,
       LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
       s);
  }
}
public void numberValue(float v) throws ParseException {
origin: org.apache.xmlgraphics/batik-bridge

/**
 * Constructs a new <code>BridgeException</code> based on the specified
 * <code>LiveAttributeException</code>.
 *
 * @param ctx the bridge context to use for determining the element's
 *            source position
 * @param ex the {@link LiveAttributeException}
 */
public BridgeException(BridgeContext ctx, LiveAttributeException ex) {
  switch (ex.getCode()) {
    case LiveAttributeException.ERR_ATTRIBUTE_MISSING:
      this.code = ErrorConstants.ERR_ATTRIBUTE_MISSING;
      break;
    case LiveAttributeException.ERR_ATTRIBUTE_MALFORMED:
      this.code = ErrorConstants.ERR_ATTRIBUTE_VALUE_MALFORMED;
      break;
    case LiveAttributeException.ERR_ATTRIBUTE_NEGATIVE:
      this.code = ErrorConstants.ERR_LENGTH_NEGATIVE;
      break;
    default:
      throw new IllegalStateException
        ("Unknown LiveAttributeException error code "
         + ex.getCode());
  }
  this.e = ex.getElement();
  this.params = new Object[] { ex.getAttributeName(), ex.getValue() };
  if (e != null && ctx != null) {
    this.line = ctx.getDocumentLoader().getLineNumber(e);
  }
}
origin: fr.avianey.apache-xmlgraphics/batik

/**
 * Constructs a new <code>BridgeException</code> based on the specified
 * <code>LiveAttributeException</code>.
 *
 * @param ctx the bridge context to use for determining the element's
 *            source position
 * @param ex the {@link LiveAttributeException}
 */
public BridgeException(BridgeContext ctx, LiveAttributeException ex) {
  switch (ex.getCode()) {
    case LiveAttributeException.ERR_ATTRIBUTE_MISSING:
      this.code = ErrorConstants.ERR_ATTRIBUTE_MISSING;
      break;
    case LiveAttributeException.ERR_ATTRIBUTE_MALFORMED:
      this.code = ErrorConstants.ERR_ATTRIBUTE_VALUE_MALFORMED;
      break;
    case LiveAttributeException.ERR_ATTRIBUTE_NEGATIVE:
      this.code = ErrorConstants.ERR_LENGTH_NEGATIVE;
      break;
    default:
      throw new IllegalStateException
        ("Unknown LiveAttributeException error code "
         + ex.getCode());
  }
  this.e = ex.getElement();
  this.params = new Object[] { ex.getAttributeName(), ex.getValue() };
  if (e != null && ctx != null) {
    this.line = ctx.getDocumentLoader().getLineNumber(e);
  }
}
origin: apache/batik

public void endNumberList() {
  if (count != 4) {
    throw new LiveAttributeException
      (element, localName,
       LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
       s);
  }
}
public void numberValue(float v) throws ParseException {
origin: apache/batik

/**
 * Constructs a new <code>BridgeException</code> based on the specified
 * <code>LiveAttributeException</code>.
 *
 * @param ctx the bridge context to use for determining the element's
 *            source position
 * @param ex the {@link LiveAttributeException}
 */
public BridgeException(BridgeContext ctx, LiveAttributeException ex) {
  switch (ex.getCode()) {
    case LiveAttributeException.ERR_ATTRIBUTE_MISSING:
      this.code = ErrorConstants.ERR_ATTRIBUTE_MISSING;
      break;
    case LiveAttributeException.ERR_ATTRIBUTE_MALFORMED:
      this.code = ErrorConstants.ERR_ATTRIBUTE_VALUE_MALFORMED;
      break;
    case LiveAttributeException.ERR_ATTRIBUTE_NEGATIVE:
      this.code = ErrorConstants.ERR_LENGTH_NEGATIVE;
      break;
    default:
      throw new IllegalStateException
        ("Unknown LiveAttributeException error code "
         + ex.getCode());
  }
  this.e = ex.getElement();
  this.params = new Object[] { ex.getAttributeName(), ex.getValue() };
  if (e != null && ctx != null) {
    this.line = ctx.getDocumentLoader().getLineNumber(e);
  }
}
origin: org.apache.xmlgraphics/batik-anim

  public void numberValue(float v) throws ParseException {
    if (count < 4) {
      numbers[count] = v;
    }
    if (v < 0 && (count == 2 || count == 3)) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
         s);
    }
    count++;
  }
});
origin: fr.avianey.apache-xmlgraphics/batik

public void endNumberList() {
  if (count != 4) {
    throw new LiveAttributeException
      (element, localName,
       LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
       s);
  }
}
public void numberValue(float v) throws ParseException {
origin: fr.avianey.apache-xmlgraphics/batik

  public void numberValue(float v) throws ParseException {
    if (count < 4) {
      numbers[count] = v;
    }
    if (v < 0 && (count == 2 || count == 3)) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
         s);
    }
    count++;
  }
});
origin: apache/batik

  public void numberValue(float v) throws ParseException {
    if (count < 4) {
      numbers[count] = v;
    }
    if (v < 0 && (count == 2 || count == 3)) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
         s);
    }
    count++;
  }
});
origin: apache/batik

/**
 * Throws an exception if the points list value is malformed.
 */
public void check() {
  if (!hasAnimVal) {
    if (baseVal == null) {
      baseVal = new BaseSVGTransformList();
    }
    baseVal.revalidate();
    if (baseVal.missing) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MISSING, null);
    }
    if (baseVal.malformed) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
         baseVal.getValueAsString());
    }
  }
}
origin: org.apache.xmlgraphics/batik-anim

/**
 * Throws an exception if the length list value is malformed.
 */
public void check() {
  if (!hasAnimVal) {
    if (baseVal == null) {
      baseVal = new BaseSVGLengthList();
    }
    baseVal.revalidate();
    if (baseVal.missing) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MISSING, null);
    }
    if (baseVal.malformed) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
         baseVal.getValueAsString());
    }
  }
}
origin: org.apache.xmlgraphics/batik-anim

/**
 * Throws an exception if the path data is malformed.
 */
public void check() {
  if (!hasAnimVal) {
    if (pathSegs == null) {
      pathSegs = new BaseSVGPathSegList();
    }
    pathSegs.revalidate();
    if (pathSegs.missing) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MISSING, null);
    }
    if (pathSegs.malformed) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
         pathSegs.getValueAsString());
    }
  }
}
origin: fr.avianey.apache-xmlgraphics/batik

/**
 * Throws an exception if the length list value is malformed.
 */
public void check() {
  if (!hasAnimVal) {
    if (baseVal == null) {
      baseVal = new BaseSVGLengthList();
    }
    baseVal.revalidate();
    if (baseVal.missing) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MISSING, null);
    }
    if (baseVal.malformed) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
         baseVal.getValueAsString());
    }
  }
}
origin: fr.avianey.apache-xmlgraphics/batik

/**
 * Throws an exception if the number list value is malformed.
 */
public void check() {
  if (!hasAnimVal) {
    if (baseVal == null) {
      baseVal = new BaseSVGNumberList();
    }
    baseVal.revalidate();
    if (baseVal.missing) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MISSING, null);
    }
    if (baseVal.malformed) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
         baseVal.getValueAsString());
    }
  }
}
origin: apache/batik

/**
 * Throws an exception if the path data is malformed.
 */
public void check() {
  if (!hasAnimVal) {
    if (pathSegs == null) {
      pathSegs = new BaseSVGPathSegList();
    }
    pathSegs.revalidate();
    if (pathSegs.missing) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MISSING, null);
    }
    if (pathSegs.malformed) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
         pathSegs.getValueAsString());
    }
  }
}
origin: fr.avianey.apache-xmlgraphics/batik

/**
 * Throws an exception if the path data is malformed.
 */
public void check() {
  if (!hasAnimVal) {
    if (pathSegs == null) {
      pathSegs = new BaseSVGPathSegList();
    }
    pathSegs.revalidate();
    if (pathSegs.missing) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MISSING, null);
    }
    if (pathSegs.malformed) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
         pathSegs.getValueAsString());
    }
  }
}
origin: org.apache.xmlgraphics/batik-anim

/**
 * Throws an exception if the points list value is malformed.
 */
public void check() {
  if (!hasAnimVal) {
    if (baseVal == null) {
      baseVal = new BaseSVGTransformList();
    }
    baseVal.revalidate();
    if (baseVal.missing) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MISSING, null);
    }
    if (baseVal.malformed) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
         baseVal.getValueAsString());
    }
  }
}
origin: apache/batik

/**
 * Throws an exception if the number list value is malformed.
 */
public void check() {
  if (!hasAnimVal) {
    if (baseVal == null) {
      baseVal = new BaseSVGNumberList();
    }
    baseVal.revalidate();
    if (baseVal.missing) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MISSING, null);
    }
    if (baseVal.malformed) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
         baseVal.getValueAsString());
    }
  }
}
origin: apache/batik

/**
 * Throws an exception if the length list value is malformed.
 */
public void check() {
  if (!hasAnimVal) {
    if (baseVal == null) {
      baseVal = new BaseSVGLengthList();
    }
    baseVal.revalidate();
    if (baseVal.missing) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MISSING, null);
    }
    if (baseVal.malformed) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
         baseVal.getValueAsString());
    }
  }
}
origin: fr.avianey.apache-xmlgraphics/batik

/**
 * Throws an exception if the points list value is malformed.
 */
public void check() {
  if (!hasAnimVal) {
    if (baseVal == null) {
      baseVal = new BaseSVGPointList();
    }
    baseVal.revalidate();
    if (baseVal.missing) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MISSING, null);
    }
    if (baseVal.malformed) {
      throw new LiveAttributeException
        (element, localName,
         LiveAttributeException.ERR_ATTRIBUTE_MALFORMED,
         baseVal.getValueAsString());
    }
  }
}
org.apache.batik.dom.svgLiveAttributeException

Javadoc

Thrown when a live attribute cannot parse an attribute's value.

Most used methods

  • <init>
    Constructs a new LiveAttributeException with the specified parameters.
  • getAttributeName
    Returns the attribute name.
  • getCode
    Returns the error code.
  • getElement
    Returns the element on which the error occurred.
  • getValue
    Returns the problematic attribute value.

Popular in Java

  • Finding current android device location
  • getApplicationContext (Context)
  • addToBackStack (FragmentTransaction)
  • getResourceAsStream (ClassLoader)
  • BorderLayout (java.awt)
    A border layout lays out a container, arranging and resizing its components to fit in five regions:
  • FileWriter (java.io)
    A specialized Writer that writes to a file in the file system. All write requests made by calling me
  • SQLException (java.sql)
    An exception that indicates a failed JDBC operation. It provides the following information about pro
  • Collections (java.util)
    This class consists exclusively of static methods that operate on or return collections. It contains
  • HashSet (java.util)
    HashSet is an implementation of a Set. All optional operations (adding and removing) are supported.
  • Runner (org.openjdk.jmh.runner)
  • Top 12 Jupyter Notebook extensions
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now