Jim,

I'm generally loath to shill for myself, but I thought that I should mention
that I am in the middle of writing a series of posts on my blog that
describe how to do just what you're describing.  I'm discussing using a
validation framework with Transfer that will allow you to add those types of
validations (and just about any type you could imagine) into your Transfer
objects.

As it seems to be an area of interest to you it might be worth a read ;-)

Cheers,
Bob

On Thu, Mar 19, 2009 at 4:25 PM, Jim <[email protected]> wrote:

>
> Yes, of course validation has to know about the properties and the
> rules.  But now if a database column is added, you have to add the
> property, you have to add the validate and you have to add it into the
> arguments of the create method of the service object and you have to
> add it to the transfer.xml.  So you're almost back to where you
> started if you just hand coded all of them whenever a change is
> needed.
>
> I'll probaby end up changing what illudium generates to I don't have
> to make all those changes when the database is modified.  I just have
> to figure out something that works for me.
>
> Ideally I'd like to see attributes added to the property tag in
> transfer.xml to add validation, like length, more granular types such
> as integer, and also range.  Then transfer could create the validation
> method.  Maybe this is in the road map, maybe not.
>
> Anyhow, just a thought.
>
> Jim
>
> On Mar 19, 3:21 pm, Russ Johnson <[email protected]> wrote:
> > I like to keep my generic validation methods in my base decorator and
> > then just call them from the beans decorator and pass in the
> > arguments... makes for a much cleaner bean decorator...
> >
> > The Transfer template in illudium is a good base but dont take it as
> > "the" way to handle it... there are many variations on that method...
> > plus you can easily create your own decorator template once you find
> > what works for you...
> >
> > On Mar 19, 2009, at 3:16 PM, Brian Kotek wrote:
> >
> >
> >
> > > If you want to validate the object's properties, clearly validation
> > > code has to know about the properties and their validation rules, yes?
> >
> > > On Thu, Mar 19, 2009 at 3:09 PM, Jim <[email protected]> wrote:
> >
> > > I've been experimenting with illudium for transfer and have a
> > > question.
> >
> > > illudium create the decorator object for transfer.  I looked at one it
> > > created and noticed two things.  One is, it has all a cfproperty for
> > > every property that corresponds to the columns in the table.  I also
> > > noticed that the validate function references the properties.
> >
> > > I thought that one of the purposes of transfer was that if a database
> > > column was added, you didn't have to go back to your bean and add in
> > > the property, getter, setter, etc.
> >
> > > Doesn't adding in the property and validate method by illudium kind of
> > > defeat this purpose?  You could always go back and regenerate the
> > > decorator, but then if you have any custom code in it, then you have
> > > to copy and paste that back in as well.
> >
> > > Thanks,
> > > Jim- Hide quoted text -
> >
> > - Show quoted text -
> >
>


-- 
Bob Silverberg
www.silverwareconsulting.com

--~--~---------~--~----~------------~-------~--~----~
Before posting questions to the group please read:
http://groups.google.com/group/transfer-dev/web/how-to-ask-support-questions-on-transfer

You received this message because you are subscribed to the Google Groups 
"transfer-dev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/transfer-dev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to