com.sun.jini.norm
Class NormServerBaseImpl.SendMonitorImpl

java.lang.Object
  extended by com.sun.jini.norm.NormServerBaseImpl.SendMonitorImpl
All Implemented Interfaces:
SendMonitor
Enclosing class:
NormServerBaseImpl

private class NormServerBaseImpl.SendMonitorImpl
extends Object
implements SendMonitor

The implementation of SendMonitor we use to track event delivery threads. Each set gets its own object.


Field Summary
private  LeaseSet set
          Set this is the monitor for
 
Constructor Summary
private NormServerBaseImpl.SendMonitorImpl(LeaseSet set)
          Simple constructor.
 
Method Summary
 void definiteException(EventType type, RemoteEvent ev, long registrationNumber, Throwable t)
          Method called when an attempt to send the event associated with this object results in a definite exception (e.g.
 boolean isCurrent()
          Should return true if the lease associated with this event is still valid and false otherwise.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

set

private final LeaseSet set
Set this is the monitor for

Constructor Detail

NormServerBaseImpl.SendMonitorImpl

private NormServerBaseImpl.SendMonitorImpl(LeaseSet set)
Simple constructor.

Parameters:
set - the set this monitor is associated with
Method Detail

definiteException

public void definiteException(EventType type,
                              RemoteEvent ev,
                              long registrationNumber,
                              Throwable t)
Description copied from interface: SendMonitor
Method called when an attempt to send the event associated with this object results in a definite exception (e.g. java.rmi.NoSuchObjectException or any other Throwable that is not a subclass of java.rmi.RemoteException.

The caller will own no locks when calling this method.

Specified by:
definiteException in interface SendMonitor
Parameters:
type - the object that generated the event
ev - the remote event that could not be sent
registrationNumber - of the event registration that generated the exception. This can be used to call EventType.clearListenerIfSequenceMatch ensure only the registration that cause the problem gets cleared.
t - the definite exception that caused us to give up sending the event

isCurrent

public boolean isCurrent()
Description copied from interface: SendMonitor
Should return true if the lease associated with this event is still valid and false otherwise.

The caller will own no locks when calling this method.

Specified by:
isCurrent in interface SendMonitor


Copyright 2007-2010, multiple authors.
Licensed under the Apache License, Version 2.0, see the NOTICE file for attributions.