FailureListener, from Charlie Groves.
A nice alternate to ComplainingListener. ComplainingListener has the wee downside of needing to compose your error text prior to making a request, even though the common case is to throw away the error string. This class has the downside of requiring a new anonymous class to be generated by the compiler every time you use it. git-svn-id: https://samskivert.googlecode.com/svn/trunk@2103 6335cc39-0255-0410-8fd6-9bcaacd3b74c
This commit is contained in:
@@ -0,0 +1,15 @@
|
|||||||
|
package com.samskivert.util;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The pessimist's dream. This ResultListener silently eats requestCompleted but makes subclasses
|
||||||
|
* handle requestFailed.
|
||||||
|
*/
|
||||||
|
public abstract class FailureListener
|
||||||
|
implements ResultListener
|
||||||
|
{
|
||||||
|
// documentation inherited from interface ResultListener
|
||||||
|
public void requestCompleted (Object result)
|
||||||
|
{
|
||||||
|
// Yeah, yeah, yeah. You did something. Good for you.
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user