And if you implement AbstractBehavior you can't reuse all the current
validators
you have to copy paste or rewrite them

If you do it the other way you have to copy paste the behavior code..
both ways its a big ugly if you ask me

johan


On 5/9/07, Eelco Hillenius <[EMAIL PROTECTED]> wrote:

On 5/9/07, Eelco Hillenius <[EMAIL PROTECTED]> wrote:
> > a problem is that IBehavior is a pretty big interface
> > And you work from the validator so its a lot of garbage a validator
will get
> > when it also implements IBehavior
> > and we don't have multiply inheritance in java so it will be very hard
to
> > reuse stuff then
> >
> > That only is possible if we have this:
> >
> > IValidator.getBehavior()
> >
> > then the validator returns the behavior it also wants to have.
> > then when add(IValidator) is called we check if it has a behavior (or
its a
> > IClientValidator or IValidatorBehavior whatever)
> > and if it has one we call add(IBehavior) with that one automatically
> >
> > This way current validators can be come client side validators very
easily
> > and one behavior can be reused  multiply times that would be much
harder if
> > it really was one big class.
>
> Good point. I'll see if I can implement this when I'm on the train to
Deventer.
>
> Eelco
>

Though I'm not yet completely convinced, as a class that extends
AbstractBehavior and implements IValidator isn't much bloat from a
user's perspective... more later.

Eelco

Reply via email to