Shall I use Value Objects?

Hi,

I am creating a web app with approx 25 web pages with not much business logic.

I plan to use struts framework.

What I wanted to know was, shall I use value object pattern for my web page?

Is there some kind of questionaire which I can take to decide whether I should use VO or not?

Thanks,

KS

[340 byte] By [Kavansa] at [2007-10-2 20:44:16]
# 1

The Value Object pattern is deprecated. Look at the DTO pattern. The DTO pattern is essentially about moving data across wires and wether you use it or not shouldn't have anything to do with how you implement your presentation layer.

Is there a questionaire? This is software development, not an issue of Comsopolitan.

dubwaia at 2007-7-13 23:27:42 > top of Java-index,Other Topics,Patterns & OO Design...
# 2

What's the difference between DTO and VO? Both are little more than C structs for ferrying data between layers. No functionality whatsoever.

"

Is there a questionaire? This is software development, not an issue of Comsopolitan."

I can see it now - "Ten Things To Do That Will Drive Your Web Clients Wild!" or "Are You Scalable? Take Our Quiz!" or "Secret Desires Of Your Server Admin."

%

duffymoa at 2007-7-13 23:27:42 > top of Java-index,Other Topics,Patterns & OO Design...
# 3

> What's the difference between DTO and VO? Both are

> little more than C structs for ferrying data between

> layers. No functionality whatsoever.

As far as I know, it was renamed because a lot of people didn't get the 'no logic' part of the definition (I've seen this with my own eyes.) The new name highlights the purpose of pattern, I guess.

dubwaia at 2007-7-13 23:27:42 > top of Java-index,Other Topics,Patterns & OO Design...
# 4

> What's the difference between DTO and VO? Both are

> little more than C structs for ferrying data between

> layers. No functionality whatsoever.

Value Object was the name used in the first editions of the Applied Java Patterns & Core J2ee Pattern books from Sun. These are called Data Transfer Objects in the later issues of these books.

The Value Object name also caused some confusion because the term has previously been used to refer to language specific ideoms of wrapping primative types in Object.

MartinS.a at 2007-7-13 23:27:42 > top of Java-index,Other Topics,Patterns & OO Design...