cancel
Showing results for 
Search instead for 
Did you mean: 

Enable Asserts

Former Member
0 Kudos

Hi,

I want to enable Asserts in NWDI (http://java.sun.com/j2se/1.4.2/docs/guide/lang/assert.html#enable-disable). How is that possible within NWDI when developing and deploying Java WD-Applications and using DTR?

Thank you and best regards,

Daniel

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Assert is only possible in Java projects. I think the reason for this is that WebDynpro will be able to generate .NET code in the future and maybe even other languages. So WebDynpro is not java only. Assert is a typical java feature.

0 Kudos

Hi,

thank you. I think that we have asserts in ABAP for some time, too - maybe longer then in Java. So I assume that ABAP WD also won't support asserts?!

Thanks and best regards,

Daniel

Answers (1)

Answers (1)

Former Member
0 Kudos

To enable (make active) assert statements, you must set a flag to the compiler.

Go to Run -> Run... -> Arguments, and in the box labeled VM arguments:, enter either -enableassertions or just -ea.

Accept the changes and close the dialog.

If you need any additional help, please let me know.

0 Kudos

Hi,

I apologize but I have a further question: I am working with Java WebDynpro and start the application via WD-App-Start. How can I enter those parameters for the WD Application? In Run->Run->WDApplication there is no possibility to enter VM arguments.

Am I wrong or is there no possibility to activate assert statements for WD Java applications?

Furthermore, if that is possible, what do we have to do in DTR for central builds and deployments to activate asserts, too?

Thank you and best regards,

Daniel

Former Member
0 Kudos

Just for your information: The central builds are done by CBS, not the DTR and the deployments are done by CMS. I don't know though if you can configure these to do what you're trying to achieve.