Class MockEditorError
- java.lang.Object
-
- com.google.gwt.editor.client.testing.MockEditorError
-
- All Implemented Interfaces:
EditorError
public class MockEditorError extends java.lang.Object implements EditorError
A trivial implementation ofEditorError. Most methods returnnull.
-
-
Constructor Summary
Constructors Constructor Description MockEditorError()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetAbsolutePath()Returns the absolute path location of the error, relative to the object that was passed into the EditorDriver.Editor<?>getEditor()Returns the Editor that holds the invalid value.java.lang.StringgetMessage()Returns a message associated with the error.java.lang.StringgetPath()Returns the path of the error relative to the Editor receiving the error.java.lang.ObjectgetUserData()Returns the object passed intoEditorDelegate.recordError(java.lang.String, java.lang.Object, java.lang.Object).java.lang.ObjectgetValue()Returns the value that triggered the error.booleanisConsumed()Always returnsfalse.voidsetConsumed(boolean consumed)No-op.
-
-
-
Method Detail
-
getAbsolutePath
public java.lang.String getAbsolutePath()
Description copied from interface:EditorErrorReturns the absolute path location of the error, relative to the object that was passed into the EditorDriver.- Specified by:
getAbsolutePathin interfaceEditorError- Returns:
- the absolute path as a String
-
getEditor
public Editor<?> getEditor()
Description copied from interface:EditorErrorReturns the Editor that holds the invalid value.- Specified by:
getEditorin interfaceEditorError- Returns:
- the Editor instance
-
getMessage
public java.lang.String getMessage()
Description copied from interface:EditorErrorReturns a message associated with the error.- Specified by:
getMessagein interfaceEditorError- Returns:
- the error message as a String
-
getPath
public java.lang.String getPath()
Description copied from interface:EditorErrorReturns the path of the error relative to the Editor receiving the error. If the error concerns the Editor that is receiving the error, this method will return an empty string.- Specified by:
getPathin interfaceEditorError- Returns:
- the error path as a String
-
getUserData
public java.lang.Object getUserData()
Description copied from interface:EditorErrorReturns the object passed intoEditorDelegate.recordError(java.lang.String, java.lang.Object, java.lang.Object).- Specified by:
getUserDatain interfaceEditorError- Returns:
- the user data Object
-
getValue
public java.lang.Object getValue()
Description copied from interface:EditorErrorReturns the value that triggered the error.- Specified by:
getValuein interfaceEditorError- Returns:
- the error value Object
-
isConsumed
public boolean isConsumed()
Always returnsfalse.- Specified by:
isConsumedin interfaceEditorError- Returns:
trueif the error will not be propagated- See Also:
EditorError.setConsumed(boolean)
-
setConsumed
public void setConsumed(boolean consumed)
No-op.- Specified by:
setConsumedin interfaceEditorError- Parameters:
consumed-trueif the error will not be propagated- See Also:
EditorError.isConsumed()
-
-