• Sun Certified Programmer for Java 2 Platform (SCJP2)
• IBM Certified Professional for Object Oriented Analysis and Design with UML
• IBM Certified System Administrator for WebSphere Application Server v5.0
• Certified Business Analysis Professional (CBAP®)
Zafar <br />***Your behaviour should affect.***
Originally posted by Vikrama Sanjeeva:
Yes Java is Fully Object Oriented!.This mean that non of the Java program can run without the creation of object.Therefore in every Java program object creation is neccessary.
The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
Associate Instructor - Hofstra University
Amazon Top 750 reviewer - Blog - Unresolved References - Book Review Blog
The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
Originally posted by yi zhu:
I don't think primitive prevents Java from being a fully OO. OO means interface and polymorphism. An object without behavior is not an true object!
When we type the following line of code
for(int i=0; i<10; i++)
we are not using any behavior of int. So here primitive is more than enough!
The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
Originally posted by yi zhu:
Oops..., in this world, we got to accept some basic facts, and Arithmetic of int is just one of them.
I don't think your code is more readable.
What's the point of the encapsulation of arithmetic of int? If you want to change implementation one day, your class will have nothing to do with int.
I would call this extreme OO.
![]()
The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
Originally posted by yi zhu:
...I don't think your code is more readable. What's the point of the encapsulation of arithmetic of int? If you want to change implementation one day, your class will have nothing to do with int. I would call this extreme OO.![]()
The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
Read about me at frankcarver.me ~ LinkedIn ~ Frank's PhD research
Originally posted by yi zhu:
Ilja,
You said that both "<" and "++" are actually behaviour of an int - and are implemented as methods in Smalltalk.
But you can also consider i+j or i<j as static methods too. (equivalent to something likeINT.sum(i, j) and INT.compare(i, j).
And without primitive, how can you build an object?
The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
Originally posted by yi zhu:
I guess I understand better your position now. (Thanks to all your explanation)![]()
But could you show me a useful OO feature that is available in Smalltalk but not in Java due to primitive? :roll:
The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
Create symphonies in seed and soil. For this tiny ad:
Clean our rivers and oceans from home
https://www.kickstarter.com/projects/paulwheaton/willow-feeders
|