diff options
author | Mark Spruiell <mes@zeroc.com> | 2010-05-13 19:05:05 -0700 |
---|---|---|
committer | Mark Spruiell <mes@zeroc.com> | 2010-05-13 19:05:05 -0700 |
commit | 308fa1d86c97997c2ec4b07671bbb113997a28cb (patch) | |
tree | f8c7dbd4b2f4f08bd78ee48d070efd2dd492b553 /java/src/Ice/Callback.java | |
parent | bug 4680 - improve IceStorm/clock demo docs (diff) | |
download | ice-308fa1d86c97997c2ec4b07671bbb113997a28cb.tar.bz2 ice-308fa1d86c97997c2ec4b07671bbb113997a28cb.tar.xz ice-308fa1d86c97997c2ec4b07671bbb113997a28cb.zip |
bug 4716 - java async API inconsistency
Diffstat (limited to 'java/src/Ice/Callback.java')
-rw-r--r-- | java/src/Ice/Callback.java | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/java/src/Ice/Callback.java b/java/src/Ice/Callback.java index 24c3004767a..debd4f55f96 100644 --- a/java/src/Ice/Callback.java +++ b/java/src/Ice/Callback.java @@ -16,4 +16,34 @@ package Ice; **/ public abstract class Callback extends IceInternal.CallbackBase { + /** + * Invoked when the invocation completes. The subclass should + * call the matching <code>end_OP</code> method on the proxy and + * must be prepared to handle exceptions. + * + * @param r The asynchronous result object returned by the <code>begin_OP</code> method. + **/ + public abstract void completed(AsyncResult r); + + /** + * Invoked when the Ice run time has passed the outgoing message + * buffer to the transport. The default implementation does nothing, + * a subclass can override it if it needs to take action when the + * message is successfully sent. + * + * @param r The asynchronous result object returned by the <code>begin_OP</code> method. + **/ + public void sent(AsyncResult r) + { + } + + public final void __completed(AsyncResult r) + { + completed(r); + } + + public final void __sent(AsyncResult r) + { + sent(r); + } } |