This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Java in General and the fly likes Is there any Macro's concept  in Java as in C and C++?? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "Is there any Macro Watch "Is there any Macro New topic

Is there any Macro's concept in Java as in C and C++??

Murali Obla
Ranch Hand

Joined: Nov 18, 2001
Posts: 40
Hi Folks,
As in C and C++ is there any Macro concept available in like #define Function.Please let me know if available

"Excellence is never an accident; it is always the result of high intention, sincere effort, intelligent direction, skillful execution, and the vision to see obstacles as opportunities"
Roy Ben Ami
Ranch Hand

Joined: Jan 13, 2002
Posts: 732
no there isnt.
Macors depend on preprocessor commands.. since java hasnt got a preprocessor (pre compiler) then it hasnt got macros as well.
Ivan Tamayo
Ranch Hand

Joined: Aug 13, 2001
Posts: 49
Fortunately, not
Mr. C Lamont Gilbert
Ranch Hand

Joined: Oct 05, 2001
Posts: 1170

"You must unlearn what you have learned." - Yoda
In fact the code becomes confusing very quickly when Macro are allowed to run free.
I agree. Here's the link:
subject: Is there any Macro's concept in Java as in C and C++??
Similar Threads
Enterprise Service Bus
I new to java and interested in certification..please advice
Pointers in Java?
How to open/execute files with unicoded fileName?