Top Description Methods
com.thoughtworks.xstream.converters

public Interface ErrorWriter

Known Direct Implementers
com.thoughtworks.xstream.converters.ErrorWritingException
Imports
java.util.Iterator

To aid debugging, some components are passed an ErrorWriter when things go wrong, allowing them to add information to the error message that may be helpful to diagnose problems.
Authors
Joe Walnes, Jörg Schaible

Method Summary

Modifier and TypeMethod and Description
public void
add(String
something to identify the type of information (e.g. 'XPath').
name
,
String
detail of the message (e.g. '/blah/moo[3]'
information
)

Add some information to the error message.

public String

Returns:

the value
get
(String
the key of the message
errorKey
)

Retrieve information of the error message.

public Iterator<E>

Returns:

an Iterator
keys
()

Retrieve an iterator over all keys of the error message.

public void
set(String
something to identify the type of information (e.g. 'XPath').
name
,
String
detail of the message (e.g. '/blah/moo[3]'
information
)

Set some information to the error message.

Method Detail

addback to summary
public void add(String name, String information)

Add some information to the error message. The information will be added even if the identifier is already in use.

Parameters
name:String

something to identify the type of information (e.g. 'XPath').

information:String

detail of the message (e.g. '/blah/moo[3]'

getback to summary
public String get(String errorKey)

Retrieve information of the error message.

Parameters
errorKey:String

the key of the message

Returns:String

the value

Since
1.3
keysback to summary
public Iterator<E> keys()

Retrieve an iterator over all keys of the error message.

Returns:Iterator<E>

an Iterator

Since
1.3
setback to summary
public void set(String name, String information)

Set some information to the error message. If the identifier is already in use, the new information will replace the old one.

Parameters
name:String

something to identify the type of information (e.g. 'XPath').

information:String

detail of the message (e.g. '/blah/moo[3]'

Since
1.4