org.relaxng.datatype
Interface ValidationContext


public interface ValidationContext

an interface that must be implemented by caller to provide context information that is necessary to perform validation of some Datatypes.

Author:
Kohsuke KAWAGUCHI

Method Summary
 boolean isNotation(java.lang.String entityName)
          checks if a notation is declared with the specified name.
 boolean isUnparsedEntity(java.lang.String entityName)
          checks if an unparsed entity is declared with the specified name.
 java.lang.String resolveNamespacePrefix(java.lang.String prefix)
          resolved namespace prefix to namespace URI.
 

Method Detail

resolveNamespacePrefix

public java.lang.String resolveNamespacePrefix(java.lang.String prefix)
resolved namespace prefix to namespace URI. this method is used for validating QName.

If the prefix is "" (empty string), it indicates unprefixed value. The implementation should resolved it as if you see an unprefixed element, rather than unprefixed attribute.

If the prefix is "xml", then the callee must resolve this prefix into "http://www.w3.org/XML/1998/namespace", as defined in the XML Namespace rec.

Returns:
namespace URI of this prefix. If the specified prefix is not declared, the implementation must return null.

isUnparsedEntity

public boolean isUnparsedEntity(java.lang.String entityName)
checks if an unparsed entity is declared with the specified name.
Returns:
true if DTD has an unparsed entity declaration for the specified name. false if otherwise.

isNotation

public boolean isNotation(java.lang.String entityName)
checks if a notation is declared with the specified name.
Returns:
true if DTD has a notation declaration with the specified name. false if otherwise.