Disclaimer

The views expressed on this blog are my own and do not necessarily reflect the views of Oracle.

Wednesday, February 10, 2010

What not to do while editing a AM method exposed to client

In a typical ADF application you would be having some AM methods exposed to client side. Whenever you expose a AM method to client side you need to go to AM and in the java you need to shuttle the method to the right.

As a result your AM.xml and AMClient.java will be modified (it will actually add the entry for the exposed method). This is fine and works good.

However, if a need arises to modify this method's signature then you should not directly go to your AM.java and modify it straight forward. Doing this may corrupt your AMClient.java file and leading to issues.

The right way is:
1. Open you AM and go to java tab.
2. Shuttle the method whose signature is to be modified towards left.
3. Now modify your method signature. save all.
4. Open you AM again and shuttle back the method.

You will also need to delete the method from the pageDefinition file where it is used and refresh the data control to add it again.

2 comments:

Anonymous said...

nice post. thanks.

Anonymous said...

very helpful article..thanks