From: Brett M. <br...@ne...> - 2001-04-20 02:49:39
|
> >> Thought I should post this to the list since we have some new blood :) > >> BTW, Welcome Brett! > > > > > > Hey there... couldn't not at least see what came of my articles ;-) > > Hope you like what you see so far :) And if you want commit access to > the repository just say the word and your in! Cool, and thanks. I'll let you know. For now, I'll just throw in my opinions here and there, as I'm swamped, but if things loosen up, I'll be hopping in with more time. Darn those full-time jobs ;-) <snip /> > > > > A couple of thoughts. First, it would make more sense to me to include the > > message element more closely with the constraint involved. This actually > > brings up something I've been thinking about: since we're now to the point > > of defining elements, and not just using the XML Schema ones, it might make > > sense to define a 'constraint' element that is the baseType for all > > constraints. Then you might have something like this: > > > > <attribute name="orderDate"> > > <jvalid:constraint uiName="Order Date" baseType="date"> > > <jvalid:minInclusive value="2/28/2001"> > > <errorMessage>The value ${value} is less than the minimum allowed > > value ${minInclusive} for ${uiName}</errorMessage> > > </jvalid:minInclusive> > > </jvalid:constraint> > > </attribute> > > > > Something like that... so jvalid:constraint would extend XML Schema's > > constraint element, jvalid:minInclusive would extend XML Schema's > > minInclusive, etc. That sort of consolidates the UI Name with the name of > > the element/attribute, which makes more sense to me. It also allows the > > error message to be a part of the constraint, which also rings truer. > > > > My 2 cents ;-) Whatcha think? > > > > -Brett > > I like! It does make much more sense this way. My idea was basically > conceived as it was written.., usually not a very good idea.., but, can > spark some lively and productive discussions :) Note to self.., think > before posting! :) Hey, I don't follow that rule myself... just happens that I've been thinking about this topic since before I wrote the first article, so I've got a few months head start. I like the idea though... I'll watch the impl and see if I can continue to be of some help. -Brett > > Mike > > > _______________________________________________ > Jvalid-devel mailing list > Jva...@li... > http://lists.sourceforge.net/lists/listinfo/jvalid-devel |