DBWS / NamingConventionTransformer [message #1044034] |
Thu, 18 April 2013 12:13 |
Kurt Geens Messages: 2 Registered: April 2013 |
Junior Member |
|
|
I'm generating a webservice using the DBWS utility based on oracle pl/sql packaged procedures. These procedures (and the types related to it) have fairly undescriptive names, so I want to change these names to meaningful ones in the webservice. For this, I'm using an override of the DefaultNamingConventionTransformer, as suggested. However, it seems that only the generateSchemaAlias function is being picked up, while both generateElementAlias and styleForElement are untouched.
To simplify debugging matters I have reduced the overwritten java class to the following:
package axirs.dbws.nct;
import org.eclipse.persistence.tools.dbws.DefaultNamingConventionTransformer;
import static org.eclipse.persistence.tools.dbws.NamingConventionTransformer.ElementStyle.ELEMENT;
public class OmzetAppNamingConventionTransformer extends DefaultNamingConventionTransformer {
@Override
public String generateSchemaAlias(String tableName) {
System.out.println("generateSchemaAlias tableName: " + tableName);
return super.generateSchemaAlias(tableName + "Type");
}
@Override
public String generateElementAlias(String originalElementName) {
System.out.println("generateElementAlias originalElementName: " + originalElementName);
return super.generateElementAlias(originalElementName);
}
@Override
public ElementStyle styleForElement(String elementName) {
System.out.println("custom styleForElement: " + elementName);
return ELEMENT;
}
}
While generating the webservice, only the tableName messages appear, the other two don't.
Example of the packages/types on which this is based:
CREATE TYPE otoaucr AS OBJECT
( deusrnm VARCHAR2(20)
, depwhsh VARCHAR2(32) );
/
CREATE TYPE otoabrs AS OBJECT
( desuccs VARCHAR2(5)
, deermsg VARCHAR2(200) );
/
CREATE OR REPLACE PACKAGE pck_app_turnover AS
PROCEDURE authenticate ( i_user_credentials IN otoaucr
, o_user_authentication OUT otoabrs );
END pck_app_turnover;
/
Any ideas on what's going wrong? I'm quite sure that my builder.xml file is correct, as the webservice generates properly. The naming convention jar has been generated correctly as well, including the manifest, as the generateSchemaAlias is picked up. I'm rather clueless as to the reason why the other 2 functions aren't...
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.06696 seconds