Plugins (1067)


Training and Consulting (40)



EPIC Poll

What is your favourite developer portal?

[ Results | Polls ]

Votes: 539
Comments: 0

Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Author Message
maxxyme
4 Post subject: [Feature Request] Change Interface DAO name  PostPosted: Jan 15, 2008 - 05:57 AM



Joined: Jan 15, 2008
Posts: 5

Although it's possible to change the generated Interface DAO java file through the IDAO.tvm template file, the generated Interface DAO name has still the same name as the DAO, due to the property "DAOInterfaceName" (in .tvm: ${class.DAOInterfaceName} , in .java: see below)

Especially, I dislike the following code:

public String getDAOClassName() {
return getValueObjectClassName() + "DAO";
}

public String getAbsoluteDAOClassName() {
return getDAOPackage() + "." + getDAOClassName();
}

public String getDAOInterfaceName() {
return getValueObjectClassName() + "DAO";
}

public String getAbsoluteDAOInterfaceName() {
return getInterfacePackage() + "." + getDAOInterfaceName();
}

Both generated class names have the same name!!! INSANE!!!
I dislike this because in Java files where you link to both the DAO and the Interface DAO... one of the two must have the entire package name pre-fixed to avoid confusion for the Java compiler, but this absolutely ugly Java code!!!

This should be configurable to allow the user to use his own pattern for Interface names, like <xxx>DAO for a DAO and I<xxx>DAO for the Interface.
More generally I think the generated class names should be customizable to allow the user to create his own whole pattern of generated Java names.
 
 View user's profile Send private message  
Reply with quote Back to top
Display posts from previous:     
Jump to:  
All times are GMT - 6 Hours
Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Powered by PNphpBB2 © 2003-2004 The PNphpBB Group
Credits