congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
DocumentComparator.printError
Code IndexAdd Tabnine to your IDE (free)

How to use
printError
method
in
org.jibx.extras.DocumentComparator

Best Java code snippets using org.jibx.extras.DocumentComparator.printError (Showing top 3 results out of 315)

origin: org.jibx/jibx-extras

/**
 * Check if two text strings match, ignoring leading and trailing spaces.
 * Any mismatch is printed immediately, with the supplied lead text.
 *
 * @param texta String to compare
 * @param textb String to compare
 * @param lead error text lead
 * @return <code>true</code> if the texts match, <code>false</code> if
 * not
 */
protected boolean matchText(String texta, String textb, String lead) {
  if (equalValues(texta, textb)) {
    return true;
  } else if (!m_schemaCompare && texta.trim().equals(textb.trim())) {
    return true;
  } else {
    printError(lead);
    if (m_differencePrint != null) {
      m_differencePrint.println(" \"" + texta +
      "\" (length " + texta.length() + " vs. \"" +
      textb + "\" (length " + textb.length() + ')');
    }
    return false;
  }
}
origin: org.jibx/jibx-extras

int typeb = m_parserB.getEventType();
if (typea != typeb) {
  printError("Different document structure");
  return false;
} else if (typea == XmlPullParser.START_TAG) {
    printError("Different start tags");
    return false;
  } else {
    printError("Different end tags");
    return false;
origin: org.jibx/jibx-extras

  if (!equalValues(value, m_parserB.getAttributeValue(j))) {
    if (match) {
      printError("Attribute mismatch");
      match = false;
  printError("Attribute mismatch");
  match = false;
if (!m_schemaCompare || !isSchemaLocation(name, ns)) {
  if (match) {
    printError("Attribute mismatch");
    match = false;
org.jibx.extrasDocumentComparatorprintError

Javadoc

Prints error description text. The generated text include position information from both documents.

Popular methods of DocumentComparator

  • <init>
    Constructor with schema adjustments flag specified. Builds the actual parsers and sets up for compar
  • compare
    Compares a pair of documents by reading them in parallel from a pair of parsers. The comparison igno
  • buildName
    Build name string.
  • buildPositionString
    Build parse input position description.
  • equalValues
    Check for equal values. If the schema compare flag is configured, this applies some basic schema rul
  • isSchemaLocation
    Check if a name/namespace pair matches a schema namespace location attribute.
  • matchAttributes
    Verifies that the attributes on the current start tags match. Any mismatches are printed immediately
  • matchNames
    Verifies that the current start or end tag names match.
  • matchText
    Check if two text strings match, ignoring leading and trailing spaces. Any mismatch is printed immed
  • normalizeDecimal
    Normalize a decimal value for comparison. A leading '+' sign is ignored, while a leading '-' is kept

Popular in Java

  • Running tasks concurrently on multiple threads
  • notifyDataSetChanged (ArrayAdapter)
  • findViewById (Activity)
  • getApplicationContext (Context)
  • DecimalFormat (java.text)
    A concrete subclass of NumberFormat that formats decimal numbers. It has a variety of features desig
  • HashSet (java.util)
    HashSet is an implementation of a Set. All optional operations (adding and removing) are supported.
  • TimeUnit (java.util.concurrent)
    A TimeUnit represents time durations at a given unit of granularity and provides utility methods to
  • Modifier (javassist)
    The Modifier class provides static methods and constants to decode class and member access modifiers
  • Filter (javax.servlet)
    A filter is an object that performs filtering tasks on either the request to a resource (a servlet o
  • IsNull (org.hamcrest.core)
    Is the value null?
  • Best plugins for Eclipse
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