Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## net.sf.saxon.lib
Class Validation

    java.lang.Object
      net.sf.saxon.lib.Validation

    public final class Validation

extends Object

This class contains constants and static methods to manipulate the validation property of a type.

Field Summary
`static int` | `BY_TYPE` Code indicating that validation against a named type was requested
`static int` | `DEFAULT` Code indicating that no specific validation options were requested
`static int` | `INVALID` Code indicating that the value of a validation request was invalid
`static int` | `LAX` Code for lax validation
`static int` | `PRESERVE` Code corresponding to the XSLT option validation=preserve, which indicates that existing type annotations are to be preserved but no new validation is performed.
`static int` | `SKIP` Synonym for `STRIP`, corresponding to XQuery usage
`static int` | `STRICT` Code for strict validation
`static int` | `STRIP` Code corresponding to the XSLT option validation=strip, which indicates that existing type annotations are to be removed and no new validation is performed.
`static int` | `VALIDATE_OUTPUT` Bit setting that can be combined with a validation code to indicate that the data being validated is final output data, and that validation errors are therefore recoverable.
`static int` | `VALIDATION_MODE_MASK` Mask used when a validation code is combined with other information in an integer value

Method Summary
`static int` | `getCode(String value)` Get the integer validation code corresponding to a given string
`static String` | `toString(int value)` Get a string representation of a validation code

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### INVALID

    public static final int INVALID

  Code indicating that the value of a validation request was invalid

  See Also:
    Constant Field Values

### STRICT

    public static final int STRICT

  Code for strict validation

  See Also:
    Constant Field Values

### LAX

    public static final int LAX

  Code for lax validation

  See Also:
    Constant Field Values

### PRESERVE

    public static final int PRESERVE

  Code corresponding to the XSLT option validation=preserve, which indicates that existing type annotations are to be preserved but no new validation is performed.

  See Also:
    Constant Field Values

### STRIP

    public static final int STRIP

  Code corresponding to the XSLT option validation=strip, which indicates that existing type annotations are to be removed and no new validation is performed.

  See Also:
    Constant Field Values

### SKIP

    public static final int SKIP

  Synonym for `STRIP`, corresponding to XQuery usage

  See Also:
    Constant Field Values

### DEFAULT

    public static final int DEFAULT

  Code indicating that no specific validation options were requested

  See Also:
    Constant Field Values

### BY_TYPE

    public static final int BY_TYPE

  Code indicating that validation against a named type was requested

  See Also:
    Constant Field Values

### VALIDATION_MODE_MASK

    public static final int VALIDATION_MODE_MASK

  Mask used when a validation code is combined with other information in an integer value

  See Also:
    Constant Field Values

### VALIDATE_OUTPUT

    public static final int VALIDATE_OUTPUT

  Bit setting that can be combined with a validation code to indicate that the data being validated is final output data, and that validation errors are therefore recoverable.

  See Also:
    Constant Field Values

Method Detail

### getCode

    public static int getCode(String value)

  Get the integer validation code corresponding to a given string

  Parameters:
    `value` - one of "strict", "lax", "preserve", or "strip"
  Returns:
    the corresponding code `STRICT`, `LAX`, `PRESERVE`, or `STRIP`

### toString

    public static String toString(int value)

  Get a string representation of a validation code

  Parameters:
    `value` - one of the validation codes defined in this class
  Returns:
    one of the strings "strict", "lax", "preserve", "skip" (sic), or "invalid"

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright (c) 2004-2010 Saxonica Limited. All rights reserved.