This week's book giveaways are in the Java EE and JavaScript forums.
We're giving away four copies each of The Java EE 7 Tutorial Volume 1 or Volume 2(winners choice) and jQuery UI in Action and have the authors on-line!
See this thread and this one for details.
The moose likes Java in General and the fly likes Java as a procedural language Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "Java as a procedural language" Watch "Java as a procedural language" New topic
Author

Java as a procedural language

Ramprasad Bhat
Greenhorn

Joined: Feb 26, 2010
Posts: 1
Just like C can simulate OOPs by using the concept of 'struct', can java too have only static methods and private constructors in all classes, pass only primitives and thereby make itself
essentially procedural ?
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41587
    
  54
Yes.


Ping & DNS - my free Android networking tools app
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19672
    
  18

You won't be able to use String though; you will need to replace it with char[]. You can't use System.out.println() either because that's calling a method of an object. So yes, you can but you will be very, very limited in what you can do.


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Java as a procedural language