com.jeantessier.commandline
Class AtLeastParameterStrategy

java.lang.Object
  |
  +--com.jeantessier.commandline.AtLeastParameterStrategy
All Implemented Interfaces:
CountingParameterStrategy, ParameterStrategy, Visitable

public class AtLeastParameterStrategy
extends java.lang.Object
implements CountingParameterStrategy

The command-line must include at least a certain number of parameters or the framework will find the command-line invalid.


Constructor Summary
AtLeastParameterStrategy(int nbParameters)
           
 
Method Summary
 boolean accept(java.lang.String param)
           
 void accept(Visitor visitor)
           
 int getCount()
           
 int getNbParameters()
           
 boolean isSatisfied()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AtLeastParameterStrategy

public AtLeastParameterStrategy(int nbParameters)
Method Detail

accept

public boolean accept(java.lang.String param)
Specified by:
accept in interface ParameterStrategy

isSatisfied

public boolean isSatisfied()
Specified by:
isSatisfied in interface ParameterStrategy

getNbParameters

public int getNbParameters()
Specified by:
getNbParameters in interface CountingParameterStrategy

getCount

public int getCount()
Specified by:
getCount in interface CountingParameterStrategy

accept

public void accept(Visitor visitor)
Specified by:
accept in interface Visitable


Dependency Finder 1.1.0 © 2001-2004 Jean Tessier.