de.nava.informa.utils.poller
Class CompositeApprover

java.lang.Object
  extended by de.nava.informa.utils.poller.CompositeApprover
All Implemented Interfaces:
PollerApproverIF

 class CompositeApprover
extends Object
implements PollerApproverIF

Composite approver uses all of its sub-approvers to form decision.

Author:
Aleksey Gureev (spyromus@noizeramp.com)

Constructor Summary
CompositeApprover()
           
 
Method Summary
 void add(PollerApproverIF approver)
          Adds new approver to the list.
 boolean canAddItem(ItemIF item, ChannelIF channel)
          Decides whether it's possible to add item to the channel or no.
 void remove(PollerApproverIF approver)
          Removes approver from the list.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CompositeApprover

CompositeApprover()
Method Detail

canAddItem

public final boolean canAddItem(ItemIF item,
                                ChannelIF channel)
Decides whether it's possible to add item to the channel or no.

Specified by:
canAddItem in interface PollerApproverIF
Parameters:
item - item to add.
channel - destination channel.
Returns:
TRUE if addition is allowed.

add

public final void add(PollerApproverIF approver)
Adds new approver to the list.

Parameters:
approver - new approver.

remove

public final void remove(PollerApproverIF approver)
Removes approver from the list.

Parameters:
approver - registered approver.


Copyright © 2002-2007 Niko Schmuck. All Rights Reserved.