Michael Jouravlev wrote:
On 8/4/05, Laurie Harper <[EMAIL PROTECTED]> wrote:
The idea of a DTO is to encapsulate the persistence logic so that it can be
independent of the model representation and business logic, and easily
replaceable.
I thought that this is the idea of DAO.
Oops, typo, I m
On 8/5/05, Leon Rosenberg <[EMAIL PROTECTED]> wrote:
> On Fri, 2005-08-05 at 08:13 -0600, Larry Meadors wrote:
>
> >
> > Who cares? is opacity not the point of Object Oriented-ness?
> >
>
> maybe. But code readability is the more important feature :-)
>
> leon
Agreed, and IMO, the C# version is
The operative word here is "if". An "if-then" statement says nothing
unless the "if" clause is true, which it is not in this case. If you
think it is, then, instead of hitchhiking on Rod, please explain how
it is. I cannot see the slightest resemblance myself.
On 8/3/05, Michael Jouravlev <[EMA
On 8/5/05, Leon Rosenberg <[EMAIL PROTECTED]> wrote:
> On Fri, 2005-08-05 at 08:13 -0600, Larry Meadors wrote:
>
> >
> > Who cares? is opacity not the point of Object Oriented-ness?
> >
>
> maybe. But code readability is the more important feature :-)
>
> leon
Agreed, and IMO, the C# version is
Agreed.
/me shudders...
Larry
On 8/5/05, Dave Newton <[EMAIL PROTECTED]> wrote:
> Daniel Perry wrote:
>
> >you can do that without the getter/setter in java as MyProperty is public.
> >
> >
> Public properties--now _that_ is evil!
>
> Dave
>
>
>
> --
On 8/5/05, Leon Rosenberg <[EMAIL PROTECTED]> wrote:
> On Thu, 2005-08-04 at 17:05 -0700, Michael Jouravlev wrote:
> > You mean, separate view from the business object, not from the data?
> > ;-) Anyway, I am not sure that this separation is needed, unless view
> > layer is developed by an evil thi
Daniel Perry wrote:
you can do that without the getter/setter in java as MyProperty is public.
Public properties--now _that_ is evil!
Dave
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMA
Leon Rosenberg wrote:
On Fri, 2005-08-05 at 08:13 -0600, Larry Meadors wrote:
Who cares? is opacity not the point of Object Oriented-ness?
maybe. But code readability is the more important feature :-)
If I'm reading the code and see a property access all I need to know is
that I'm acce
thing though... your executing code
to set and get private properties of an object. The original topic here
is "DTOs are evil", and it seems to me that the syntax of C# wouldn't
change a persons' opinion on that question, right?
I mean, if DTOs are evil in your mind, they aren'
On Fri, 2005-08-05 at 08:13 -0600, Larry Meadors wrote:
>
> Who cares? is opacity not the point of Object Oriented-ness?
>
maybe. But code readability is the more important feature :-)
leon
-
To unsubscribe, e-mail: [EMAIL
On 8/5/05, Leon Rosenberg <[EMAIL PROTECTED]> wrote:
> On Fri, 2005-08-05 at 07:18 -0600, Larry Meadors wrote:
> > You don't see it?!? Have you looked?
> >
> > As a self-professed Java bigot, I will readily admit that C# has a
> > *way* better sytax for defining and using properties that I wish Jav
eh? you can do that without the getter/setter in java as MyProperty is
public.
Daniel.
> -Original Message-
> From: Larry Meadors [mailto:[EMAIL PROTECTED]
> Sent: 05 August 2005 14:18
> To: Struts Users Mailing List
> Subject: Re: [OT] DTOs are evil
>
>
> You
On Fri, 2005-08-05 at 07:18 -0600, Larry Meadors wrote:
> You don't see it?!? Have you looked?
>
> As a self-professed Java bigot, I will readily admit that C# has a
> *way* better sytax for defining and using properties that I wish Java
> would implement (or even better - improve upon).
>
> publ
You don't see it?!? Have you looked?
As a self-professed Java bigot, I will readily admit that C# has a
*way* better sytax for defining and using properties that I wish Java
would implement (or even better - improve upon).
public string MyProperty {
get { return myProperty; }
set
P.S. By the way, Rod Johnson also said persistent objects that contain only
getters and setters are evil too (same page as dto, 27). In my understanding
it means hibernate and ibatis which use such objects are at least as evil?
How are you supposed to represent data anyway then?
the issue is not
> employeeDAO.updateEmployee( employee );
>
> From what I recall the real OO way would be...
>
> employee.update();
>
> and employee takes care of updating itself.
>
I made a BaseBO using OJB, which has the create, update, softDelete,
hardDelete, findById, findByCriteria methods. It also has an
may say that the DTO's are not OO, because they only contain state and
> > no behaviour. That's right, but com'on, we are talking about java here, and
> > java isn't a simple OO language, but a component-oriented language, and DTOs
> > are part of the component
Michael Jouravlev wrote:
Yes, this is exactly what I mean. This is evil. I take that you have
not used Object Pascal?
I've actually seen it, although I can't say I've personally used it.
property MaxLength: Integer read FMaxLength write SetMaxLength default 0;
There's nothing to stop you
On 8/4/05, Frank W. Zammetti <[EMAIL PROTECTED]> wrote:
> Michael Jouravlev wrote:
> > If getters and setters do nothing more than simply read field or set
> > field, then they are evil, you do not need Rod Johnson to tell you
> > that ;)
>
> I think I may... why exactly is this evil?
>
> We're t
Michael Jouravlev wrote:
If getters and setters do nothing more than simply read field or set
field, then they are evil, you do not need Rod Johnson to tell you
that ;)
I think I may... why exactly is this evil?
We're talking, at the most basic level, about a construct that
encapsulates prop
t a simple OO language, but a component-oriented language, and DTOs
> are part of the component definition.
>
> As for Rod Johnson, he said that DTOs are evil if you don't want to
> distribute the application (arguable point btw, because i believe we should
> provide
Rick Reumann on 04/08/05 19:12, wrote:
In particular, CRUD actions are not behaviour of the business object
('save employee object to the database' is not an operation that makes
sense in the context of the business domain, it's an implementation
artifact [speaking broadly]). That's partly wha
> -Ursprüngliche Nachricht-
> Von: Michael Jouravlev [mailto:[EMAIL PROTECTED]
> Gesendet: Donnerstag, 4. August 2005 23:27
> An: Struts Users Mailing List
> Betreff: Re: DTOs are evil
> So, DTOs are useful where:
> * model was done incorrectly
> * in cases of
On 8/4/05, Laurie Harper <[EMAIL PROTECTED]> wrote:
> The idea of a DTO is to encapsulate the persistence logic so that it can be
> independent of the model representation and business logic, and easily
> replaceable.
I thought that this is the idea of DAO.
> There's nothing saying you can't put
On Thu, August 4, 2005 2:12 pm, Dave Newton said:
> Frank W. Zammetti wrote:
>
>>ArrayList getClientList();
>>ClientDTO getClientInfo(String id);
>>boolean saveClient(ClientDTO client);
>>boolean deleteClient(String id);
>
> (Hey, shouldn't getClientList return a List? ;)
Yep, I suppose it should
Laurie Harper wrote the following on 8/4/2005 12:58 PM:
Looking up lists of things is sort of a meta-concern; you're right,
putting that on the Employee object would clutter things up, especially
when you start needing more complex queries -- e.g.
getEmployeesEligibleForPerformanceBonus() etc.
Frank W. Zammetti wrote:
ArrayList getClientList();
ClientDTO getClientInfo(String id);
boolean saveClient(ClientDTO client);
boolean deleteClient(String id);
In any case, only these FBs know anything about how the data is stored.
I do much the same thing defined as an interface so I can swi
Rick Reumann wrote:
I do agree, though, with what others have said that DTOs/ValueObjects
aren't really that OO. It's funny that the subject comes up because I
was a late bloomer to the programming world (started about 6 years and
was a waiter and science teacher before that:), and when I first
ew EmployeeManager();
> ArrayList employees = manager.getEmployees();
>
> And the method gets all the keys in a separate piece of SQL and then calls
> the code I have shown above.
>
> -Original Message-
> From: Rick Reumann [mailto:[EMAIL PROTECTED]
> Sent: 04 August 2005
On 8/4/05, Laurie Harper <[EMAIL PROTECTED]> wrote:
> Rick Reumann wrote:
> > Michael Jouravlev wrote the following on 8/3/2005 9:07 PM:
> >> http://www.theserverside.com/news/thread.tss?thread_id=35233
> > Just curious what are Rod's exact views on the DTO? I searched for DTOs
> > on that link you
Rick Reumann wrote:
Michael Jouravlev wrote the following on 8/3/2005 9:07 PM:
http://www.theserverside.com/news/thread.tss?thread_id=35233
Just curious what are Rod's exact views on the DTO? I searched for DTOs
on that link you posted but only saw posts by other people.
Mechael's referring t
o: Struts Users Mailing List
Subject: Re: DTOs are evil
Michael Jouravlev wrote the following on 8/3/2005 9:07 PM:
> http://www.theserverside.com/news/thread.tss?thread_id=35233
>
Just curious what are Rod's exact views on the DTO? I searched for DTOs
on that link you posted but only saw
Michael Jouravlev wrote the following on 8/3/2005 9:07 PM:
http://www.theserverside.com/news/thread.tss?thread_id=35233
Just curious what are Rod's exact views on the DTO? I searched for DTOs
on that link you posted but only saw posts by other people.
I do agree, though, with what others ha
http://www.theserverside.com/news/thread.tss?thread_id=35233
If Rod Johnson have the same position on DTOs as me, should I be twice
confident in my point of view? ;-)
Michael.
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For addi
34 matches
Mail list logo