FileDocCategorySizeDatePackage
XMLErrorCode.javaAPI DocJava SE 6 API2279Tue Jun 10 00:22:52 BST 2008com.sun.org.apache.xerces.internal.util

XMLErrorCode

public final class XMLErrorCode extends Object

A structure that represents an error code, characterized by a domain and a message key.

author
Naela Nissar, IBM
version
$Id: XMLErrorCode.java,v 1.3 2005/09/26 13:03:01 sunithareddy Exp $

Fields Summary
private String
fDomain
error domain
private String
fKey
message key
Constructors Summary
public XMLErrorCode(String domain, String key)

Constructs an XMLErrorCode with the given domain and key.

param
domain The error domain.
param
key The key of the error message.

        fDomain = domain;
        fKey = key;
    
Methods Summary
public booleanequals(java.lang.Object obj)

Indicates whether some other object is equal to this XMLErrorCode.

param
obj the object with which to compare.

        if (!(obj instanceof XMLErrorCode))
            return false;
        XMLErrorCode err = (XMLErrorCode) obj;
        return (fDomain.equals(err.fDomain) && fKey.equals(err.fKey));
    
public inthashCode()

Returns a hash code value for this XMLErrorCode.

return
a hash code value for this XMLErrorCode.

        return fDomain.hashCode() + fKey.hashCode();
    
public voidsetValues(java.lang.String domain, java.lang.String key)

Convenience method to set the values of an XMLErrorCode.

param
domain The error domain.
param
key The key of the error message.

        fDomain = domain;
        fKey = key;