com.sun.jini.norm
Class LeaseExpirationMgr.MgrTask

java.lang.Object
  extended by com.sun.jini.norm.LeaseExpirationMgr.MgrTask
All Implemented Interfaces:
Runnable
Direct Known Subclasses:
LeaseExpirationMgr.QueueExpiration, LeaseExpirationMgr.SendWarning
Enclosing class:
LeaseExpirationMgr

private abstract class LeaseExpirationMgr.MgrTask
extends Object
implements Runnable

Utility base class for our tasks, mainly provides the the proper locking for manipulating the ticketMap.


Field Summary
protected  WeakReference resourceRef
          Resource this task is to operate on
private  WakeupManager.Ticket ticket
          Ticket for this task
 
Constructor Summary
protected LeaseExpirationMgr.MgrTask(LeaseSet set)
          Simple constructor.
 
Method Summary
protected  LeaseSet removeOurTicket()
          Removes this task's ticket from the ticket map iff this task's ticket is in the map.
abstract  void run()
           
private  void setTicket(WakeupManager.Ticket ticket)
          Set the ticket associated with this task.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

resourceRef

protected final WeakReference resourceRef
Resource this task is to operate on


ticket

private WakeupManager.Ticket ticket
Ticket for this task

Constructor Detail

LeaseExpirationMgr.MgrTask

protected LeaseExpirationMgr.MgrTask(LeaseSet set)
Simple constructor.

Parameters:
set - the set this task is to operate on
Method Detail

setTicket

private void setTicket(WakeupManager.Ticket ticket)
Set the ticket associated with this task.


removeOurTicket

protected LeaseSet removeOurTicket()
Removes this task's ticket from the ticket map iff this task's ticket is in the map. Returns the LeaseSet this task is to operate on or null if this task should stop.


run

public abstract void run()
Specified by:
run in interface Runnable


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