commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rob Oxspring" <roxspr...@imapmail.org>
Subject Re: [CLI][PATCH] Min and Max size for arguments
Date Wed, 11 Jun 2003 10:00:17 GMT

----- Original Message ----- 
From: "John Keyes" <jbjk@mac.com>
To: "Jakarta Commons Developers List" <commons-dev@jakarta.apache.org>
Sent: Wednesday, June 11, 2003 12:27 AM
Subject: Re: [CLI][PATCH] Min and Max size for arguments


> > ArgumentBuilder.withSize(int) has been retained and sets both min and
> > max to the same.  (This might be a bad thing if both size and
> > min/max are specified though).
> I think that we can remove withSize, if someone calls withMaximumSize
> then the
> minSize should be set to 1 automatically.  It should be explicit for
> someone to
> specify a minimum size of 0 i.e. an optional value.

Sound good.

>
> > ArgumentBuilder.withOptionalValues(boolean) has been removed since its
> > a function of the min and max values.
> >
> > Argument.hasOptionalValues() has been retained and returns min<max
> This should just return min == 0?  If min is > 0 then that means a
> value is
> required.

Hmm, there's room for confusion here.  My implementation of hasOptionalValues() says "are
any values optional" whereas yours says
"are all values optional".  I suspect that we should just drop the method and get people to
ask the question they mean to by using
getMin/Max.


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message