on 10-07-2008 4:59 PM
hi all,
I want to modify a java file that is generated when you create the webdynpro, but I can not change.
// -
// This file has been generated partially by the Web Dynpro Code Generator.
// MODIFY CODE ONLY IN SECTIONS ENCLOSED BY @@begin AND @@end.
// ALL OTHER CHANGES WILL BE LOST IF THE FILE IS REGENERATED.
// -
how can I disable the file to modify
thanks!
Hi Pablo.
There's no way to modify it, NW2004s and its IDE has a code compilation based in some internal scripts based on eclipse plugin architecture.
In your code you must consider this.
1 - Try to find in your declared methods, importing directives, packages declarations some like this:
// -
// This file has been generated partially by the Web Dynpro Code Generator.
// MODIFY CODE ONLY IN SECTIONS ENCLOSED BY @@begin AND @@end.
// ALL OTHER CHANGES WILL BE LOST IF THE FILE IS REGENERATED.
// -
package com.sap.teste;
//
// IMPORTANT NOTE:
// ALL IMPORT STATEMENTS MUST BE PLACED IN THE FOLLOWING SECTION ENCLOSED
// BY @@begin imports AND @@end. FURTHERMORE, THIS SECTION MUST ALWAYS CONTAIN
// AT LEAST ONE IMPORT STATEMENT (E.G. THAT FOR IPrivateTesteApp).
// OTHERWISE, USING THE ECLIPSE FUNCTION "Organize Imports" FOLLOWED BY
// A WEB DYNPRO CODE GENERATION (E.G. PROJECT BUILD) WILL RESULT IN THE LOSS
// OF IMPORT STATEMENTS.
//
//@@begin imports
import com.sap.teste.wdp.IPrivateTesteApp;
import com.sap.myimport.MyClass;
//@@end
//@@begin
//@@end
it means that between begin and end...you can add what you want..and the code will not be removed after class compilation....
//@@begin javadoc:wdDoExit()
/** Hook method called to clean up controller. */
//@@end
public void wdDoExit()
{
//@@begin wdDoExit()
//@@end
}
int this case too....if you implement something between //@@begin and //@@end in the method scope...all part of your code will be surely safe.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.