Regardinf #define or build flag

by Dilip Dilip » Thu, 11 Mar 2010 11:28:51 GMT

Sponsored Links
 Hi All,
  Please tell me how to declare equivalent of #define in java ? whats the
best way and best place in android to define equivalent of it.
my requirement is some thing like this ...
if the flag is enabled that part of the code should get complile else it
should not compile.

something like




can some one please explain me how to this in java.
basically i want a build flag which applies to whole android.

Thanks a lot in Advance.

THanks and Regards,


Other Threads

1. SurfaceView and Menu created


It seems that android Menu doesn't work on SurfaceView.  Menu cannot
render when the view is the SurfaceView.

Anybody have the same problems ?


2. 2.2 froyo ssl handshake failure with DefaultHttpClient


Mark Murphy (a Commons Guy) | |

Android Training in US: 14-18 June 2010:


3. Keyboard and EditText in landscape

4. 2.2 froyo ssl handshake failure with DefaultHttpClient

5. which method/function causing "App freeze timeout expired."?

6. Application Crashes when Orientation changes - Very Urgent plz

7. Change in the way input-lines act when updating to Android 2.2...