This week's book giveaway is in the Agile and Other Processes forum.
We're giving away four copies of Real-World Software Development: A Project-Driven Guide to Fundamentals in Java and have Dr. Raoul-Gabriel Urma & Richard Warburton on-line!
See this thread for details.
Win a copy of Real-World Software Development: A Project-Driven Guide to Fundamentals in Java this week in the Agile and Other Processes forum!

Mark Pereira

Greenhorn
+ Follow
since Aug 01, 2011
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Mark Pereira

Hey! It works! I was doing everything fine but I dont know why Netbeans was not generating well rpc file I tried with Eclipse and it works, after using GWT Compiler.

Thanks for your attention,
Marco


Maneesh Godbole wrote:Entities are the classes you get from Hibernate. They have hibernate related and other annotations.
DTOs are the POJOs which correspond with these Entities. DTOs are serializable and do not have any annotations.

Where are your entity classes? Under server?
Do you have a converter code or some other facility which converts Entity<->DTO?

Remember, everything under shared has to be serializable, and the source code should be available for the GWT compiler, including the source code for annotations.

8 years ago
GWT
yes, all of my DTOs implement Serializable and have a no-args constructor.

My DTOs in client side dont have hibernate annotations, but entity classes in another package have, cause I need them.

I really dont know what to try more...

Maneesh Godbole wrote:So you got ComponentDTO ActivityLockDTO ActivityTypeDTO ActivityPermissionDTO inside your ActivityDTO.
Do all these DTOs implement Serializable and and an default constructor?

The entities but with hibernate annotations are in another package (shared)


I am not sure I understand this. Do your DTO have hibernate annotations?

8 years ago
GWT
Hey, thanks for your answer. Below I put the ActivityDTO class. I have this in client package like the others DTOs.
The entities but with hibernate annotations are in another package (shared), and when I make the query in server service class and return the object appears the serialization error.
Thanks for trying to help ;)

8 years ago
GWT
Hey everyone.

I made DTOs to get over the serialization problem and still have the same error:
Caused by: com.google.gwt.user.client.rpc.SerializationException: Type 'com.client.ActivityDTO' was not included in the set of types which can be serialized by this SerializationPolicy or its Class object could not be loaded. For security purposes, this type will not be serialized.:

I have the entities with annotations in a shared package (client and server) and have dtos in client side. I have an empty contructor in all entities and they are all serialized.

Can anybody help me? I am getting desperate with this.

Thanks, Mark
8 years ago
GWT