473,385 Members | 1,867 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Java classes comments

13,262 8TB
Post comments and questions on the java classes in this thread.
Dec 27 '06 #1
50 5537
ronverdonk
4,258 Expert 4TB
You'd better make this thread a sticky or it will slowly, but surely, sink out of sight.

Ronald :cool:
Dec 28 '06 #2
r035198x
13,262 8TB
You'd better make this thread a sticky or it will slowly, but surely, sink out of sight.

Ronald :cool:

I thought of that but then the number of stickies was getting on my nerves. I've provided links in the classes that link to this thread though.
Dec 29 '06 #3
carly
37
Cant wait for the next class :D ........ really like the way your explaining things!!

Thanks!!

Carly ;)
Jan 1 '07 #4
r035198x
13,262 8TB
Cant wait for the next class :D ........ really like the way your explaining things!!

Thanks!!

Carly ;)
Thanks for the comments. I'll try to get the next class up tommorrow.
Jan 2 '07 #5
r035198x
13,262 8TB
Got delayed by having to format my computer. Expect next class in a couple of hours.
Jan 4 '07 #6
r035198x
13,262 8TB
Third class is finally up
Jan 5 '07 #7
Ganon11
3,652 Expert 2GB
Ooh, in two posts!

It all looks good, r0 - I'll take a closer look during my free period today. Keep up the good work.

Also, what parts of the String class are you planning on going over?
Jan 5 '07 #8
r035198x
13,262 8TB
Ooh, in two posts!

It all looks good, r0 - I'll take a closer look during my free period today. Keep up the good work.

Also, what parts of the String class are you planning on going over?
In the classes I will be going over some of the most commonly used Java classes like String, ArrayList etc. The next examples I'll use will include Strings so I'll introduce how to use that class first and also look at some differences between == and .equals when comparing Strings plus a look at some of its commonly used methods. Just the basics to get one started in using Strings.

Thanks for the comments.
Jan 5 '07 #9
r035198x
13,262 8TB
Guys I realize that the next class is running very late. I promise to get it up by the end of this week.
Feb 1 '07 #10
I know that JRE and JDK are products delivered under the java platform and JRE provides the libraries,JVM, and ather components necessary for running Application. JDK includes the JRE plus command-line development tools such as compilers and debugger.

But I have some questions and confusions,
1-What is the command-line?
2-what is the difference between JVM's Role and command-line's Role?
3-the debugger is the interpreter or java that launch the application and the interpreter is the JVM???So the debugger is the interpreter or the JVM?
Feb 3 '07 #11
I don't understand why does not the following code compile ?

Expand|Select|Wrap|Line Numbers
  1. byte a = 12;
  2. a = a + 1;
Feb 3 '07 #12
What do you mean by the Embedded keywords or literals ???
Feb 3 '07 #13
r035198x
13,262 8TB
I know that JRE and JDK are products delivered under the java platform and JRE provides the libraries,JVM, and ather components necessary for running Application. JDK includes the JRE plus command-line development tools such as compilers and debugger.

But I have some questions and confusions,
1-What is the command-line?
2-what is the difference between JVM's Role and command-line's Role?
3-the debugger is the interpreter or java that launch the application and the interpreter is the JVM???So the debugger is the interpreter or the JVM?
Command line is just the prompt where you run your commands like MsDos prompt. It is not part of the j.d.k kit but is part of your OS. It's just an interface for running your programs.
Feb 5 '07 #14
r035198x
13,262 8TB
I don't understand why does not the following code compile ?

Expand|Select|Wrap|Line Numbers
  1. byte a = 12;
  2. a = a + 1;
The + operator is not applicable to the primitive type byte. It works for numeric types starting from int upwards.
The ++ operator, however, performs an implicit type cast to int so

Expand|Select|Wrap|Line Numbers
  1.  byte a = 12; 
  2. a++;
  3.  
will compile because a is converted to int first
Feb 5 '07 #15
r035198x
13,262 8TB
What do you mean by the Embedded keywords or literals ???
apublics is allowed as an identifier even though it embeds the keyword public and test1 is also allowed as a keyword even though it has the literal 1 in it.
Feb 5 '07 #16
r035198x
13,262 8TB
Inheritance class is finally up. Just keep the comments, questions, analysis and criticisms coming here in this thread.
Feb 6 '07 #17
hirak1984
316 100+
Well fine to see this new discussions on java classes.Really awaiting when it will come upto collection frameworks,struts etc.Or did you already covered the topics?
Inheritance class is finally up. Just keep the comments, questions, analysis and criticisms coming here in this thread.
Feb 12 '07 #18
r035198x
13,262 8TB
Well fine to see this new discussions on java classes.Really awaiting when it will come upto collection frameworks,struts etc.Or did you already covered the topics?
Not yet. Just those topics in those classes have been covered so far. Struts tutorial wasn't part of the plan but I might include it in the J2EE tutorials that I'm thinking of starting as well.
Feb 12 '07 #19
hirak1984
316 100+
That will be so nice of you,and verrrry helpful for people like me.
Not yet. Just those topics in those classes have been covered so far. Struts tutorial wasn't part of the plan but I might include it in the J2EE tutorials that I'm thinking of starting as well.
Feb 12 '07 #20
abctech
157 100+
Please do start J2EE tutorials too side by side with the ongoing Java tutorials if you get time r0, can't wait to read them !!!
Feb 12 '07 #21
java classes are pureley object oriented...All help to better application development than aany other languages
Feb 14 '07 #22
r035198x
13,262 8TB
java classes are pureley object oriented...All help to better application development than aany other languages
Not really. Just having a class in your program does not mean that your code is object oriented. That is why Java is not purely object-oriented because you can write code that is not object oreinted with it.
Feb 14 '07 #23
abctech
157 100+
java classes are pureley object oriented...All help to better application development than aany other languages
Java isn't purely an OO language because it has basic(primitive) types that are not objects,.. a trade off of purity for practicality.
Feb 14 '07 #24
r035198x
13,262 8TB
Java isn't purely an OO language because it has basic(primitive) types that are not objects,.. a trade off of purity for practicality.
True.

If you have a language in which evrything is an object, the language would become purely Object-Based not Object-Oriented.
Feb 14 '07 #25
abctech
157 100+
True.

If you have a language in which evrything is an object, the language would become purely Object-Based not Object-Oriented.
I am a bit confused between purely Object-Based and purely OO languages. Can you elaborate please?

Is VB an Object Based language? Do we have any example of a purely OO language?
Feb 14 '07 #26
r035198x
13,262 8TB
I am a bit confused between purely Object-Based and purely OO languages. Can you elaborate please?

Is VB an Object Based language? Do we have any example of a purely OO language?
A purely object oriented laguage would not only support object oriented design. It would have to have some level of enforcing object oriented design concepts. I don't know whether VB is object based or not but if everything is an object then the language is object based. Smalltalk is an example of a purely object-oriented language.
Here is an article talking about these things.
Feb 14 '07 #27
abctech
157 100+
A purely object oriented laguage would not only support object oriented design. It would have to have some level of enforcing object oriented design concepts. I don't know whether VB is object based or not but if everything is an object then the language is object based. Smalltalk is an example of a purely object-oriented language.
Here is an article talking about these things.
Thanks for the link r035198x. Here's another link I just came across related to this.
Feb 14 '07 #28
shy001
1
Post comments and questions on the java classes in this thread.
hi i need help with something
i have
public class Name implements NameInterface
{
......
}
getting this error

C:\Program Files\Xinox Software\JCreator\MyProjects\Test1\Name.java:1: Name should be declared abstract; it does not define setName(java.lang.String,java.lang.String) in Name
class Name implements Comparable, NameInterface
^
1 error
Process completed.
Feb 16 '07 #29
r035198x
13,262 8TB
hi i need help with something
i have
public class Name implements NameInterface
{
......
}
getting this error

C:\Program Files\Xinox Software\JCreator\MyProjects\Test1\Name.java:1: Name should be declared abstract; it does not define setName(java.lang.String,java.lang.String) in Name
class Name implements Comparable, NameInterface
^
1 error
Process completed.
Start a new thread for this. This thread is reserved for comments to Free Java Classes thread only.
Feb 16 '07 #30
hi... i want to learn java..how to start up... i hve got knowledge of C,C++...
now plz assist....
Feb 27 '07 #31
r035198x
13,262 8TB
hi... i want to learn java..how to start up... i hve got knowledge of C,C++...
now plz assist....
Read this and also this
Feb 27 '07 #32
shana07
281 100+
I have just finished reading your free java classes...
Your writing clear and good.
Hopefully after this I won't ask silly java question anymore :)
Thanks
Mar 14 '07 #33
r035198x
13,262 8TB
I have just finished reading your free java classes...
Your writing clear and good.
Hopefully after this I won't ask silly java question anymore :)
Thanks
Don't worry about asking silly questions.
That's how we all learn.

Thanks for taking time to read them.
Mar 14 '07 #34
r035198x
13,262 8TB
[font=Verdana][size=2]horace1 has done a good job with the next part of the lessons. [/size][/font]
Apr 11 '07 #35
I have a project that I want assistance with but can't see where to attach files. If anyone would like a java programming challenge let me know

Donald
May 2 '07 #36
r035198x
13,262 8TB
I have a project that I want assistance with but can't see where to attach files. If anyone would like a java programming challenge let me know

Donald
You'll get all the assistance you need if you are willing to be doing the work yourself. When you do get stuck with a particular problem, just start a new thread in the forum and the experts there will be glad to help.
May 2 '07 #37
madhoriya22
252 100+
Post comments and questions on the java classes in this thread.
Hi r035198x,

Such a nice article on java basics......My question is regarding Abstract classes.......If abstract classes dont have objects then what contructors are doing there..........Here I am giving you the code snippet........will u please explain it for me
Expand|Select|Wrap|Line Numbers
  1. DAOFactory mysqlFactory = DAOFactory.getDAOFactory(DAOFactory.MYSQL);//DAOFactory is a abstract class
  2.  
  3. //method getDAOFactory() is like this:-
  4.  public static DAOFactory getDAOFactory(int whichFactory) {
  5.         switch (whichFactory) {
  6.  
  7.             case 1:
  8.             // return new OracleDAOFactory(dbSource);
  9.             case 2:
  10.             // return new SybaseDAOFactory(); 
  11.             case 3:    
  12.                 return new MySqlDAOFactory();//MySqlDAOFactory is the class implementing DAOFactory                
  13.             default:
  14.                 return null;
  15.         }
  16.     }
  17.  
aren't we creating a abstract class object(mysqlFactory) here.......
I am a bit confused here ........
Thanks,
madhoriya
Jul 24 '07 #38
r035198x
13,262 8TB
Hi r035198x,

Such a nice article on java basics......My question is regarding Abstract classes.......If abstract classes dont have objects then what contructors are doing there..........Here I am giving you the code snippet........will u please explain it for me
Expand|Select|Wrap|Line Numbers
  1. DAOFactory mysqlFactory = DAOFactory.getDAOFactory(DAOFactory.MYSQL);//DAOFactory is a abstract class
  2.  
  3. //method getDAOFactory() is like this:-
  4.  public static DAOFactory getDAOFactory(int whichFactory) {
  5.         switch (whichFactory) {
  6.  
  7.             case 1:
  8.             // return new OracleDAOFactory(dbSource);
  9.             case 2:
  10.             // return new SybaseDAOFactory(); 
  11.             case 3:    
  12.                 return new MySqlDAOFactory();//MySqlDAOFactory is the class implementing DAOFactory                
  13.             default:
  14.                 return null;
  15.         }
  16.     }
  17.  
aren't we creating a abstract class object(mysqlFactory) here.......
I am a bit confused here ........
Thanks,
madhoriya
Is DAOFactory an interface or a method? Even if it were an abstract class, what's being created there is a MySqlDAOFactory object which is being created from a non abstract class.
Jul 24 '07 #39
JosAH
11,448 Expert 8TB
Is DAOFactory an interface or a method? Even if it were an abstract class, what's being created there is a MySqlDAOFactory object which is being created from a non abstract class.
You must be having a bad hairday ;-) you can't return methods; DAOFactory is
either an abstract class or an interface. That snippet must be part of an abstract
factory and it returns the appropriate factory given some database indicator.

kind regards,

Jos
Jul 24 '07 #40
madhoriya22
252 100+
Is DAOFactory an interface or a method? Even if it were an abstract class, what's being created there is a MySqlDAOFactory object which is being created from a non abstract class.
DAOFactory is a abstract class....I have already given that as comment.
One question is still there to be answered....What is contructors doing in abstract class if we cant create object of that.....

regards,
madhoriya
Jul 24 '07 #41
madhoriya22
252 100+
You must be having a bad hairday ;-) you can't return methods; DAOFactory is
either an abstract class or an interface. That snippet must be part of an abstract
factory and it returns the appropriate factory given some database indicator.

kind regards,

Jos
You are absolutely correct Jos.....
But why u people are keep guessing that what is DAOFactory....
I have already written that as comment in code that it is a abstract class....

Sorry I posted it twice......i dont know how to delete it.....as there is no option of deleting
Jul 24 '07 #42
madhoriya22
252 100+
You must be having a bad hairday ;-) you can't return methods; DAOFactory is
either an abstract class or an interface. That snippet must be part of an abstract
factory and it returns the appropriate factory given some database indicator.

kind regards,

Jos
You are absolutely correct Jos.....
But why u people are keep guessing that what is DAOFactory....
I have already written that as comment in code that it is a abstract class....

Thanks and regards,
madhoriya
Jul 24 '07 #43
r035198x
13,262 8TB
You must be having a bad hairday ;-) you can't return methods; DAOFactory is
either an abstract class or an interface. That snippet must be part of an abstract
factory and it returns the appropriate factory given some database indicator.

kind regards,

Jos
I'm a good candiadate for the d word today.
I was going to type interface or abstract class.
Sorry about that.
@OP.I just wanted to know whether DAOFactory was an interface or an abstract class. But that doesn't matter anyway in this case.
I hope you've been answered?
Jul 24 '07 #44
JosAH
11,448 Expert 8TB
I'm a good candiadate for the d word today.
I was going to type interface or abstract class.
Sorry about that.
No need to apologize; I suffer from the same dexter-sapiens syndrome too now
and then: my fingers start thinking for themselves and think they know better:
I want to type "make", my fingers type "main", I want to type "do" and my
fingers complete it as "double" etc. etc.

Silly fingers,

kill -9 register,

Java ;-)
Jul 24 '07 #45
r035198x
13,262 8TB
No need to apologize; I suffer from the same dexter-sapiens syndrome too now
and then: my fingers start thinking for themselves and think they know better:
I want to type "make", my fingers type "main", I want to type "do" and my
fingers complete it as "double" etc. etc.

Silly fingers,

kill -9 register,

Java ;-)
And I've just moved from Vista to Fedora as well (Not that I'm complaining about the move of course).
Jul 24 '07 #46
madhoriya22
252 100+
And I've just moved from Vista to Fedora as well (Not that I'm complaining about the move of course).
hi r035198x/Jos,
One question is still there to be answered....What is contructors doing in abstract class if we cant create object of that.....suggest me on that one....plzz

Thanks and regard,
madhoriya
Jul 25 '07 #47
JosAH
11,448 Expert 8TB
hi r035198x/Jos,
One question is still there to be answered....What is contructors doing in abstract class if we cant create object of that.....suggest me on that one....plzz

Thanks and regard,
madhoriya
You may not be able to create an instance from an abstract class, you may be
very well able to instantiate an object from a concrete subclass. A class
constructor always (implicitly) calls its superclass' constructor so an abstract
class needs at least one constructor as well.

kind regards,

Jos
Jul 25 '07 #48
r035198x
13,262 8TB
hi r035198x/Jos,
One question is still there to be answered....What is contructors doing in abstract class if we cant create object of that.....suggest me on that one....plzz

Thanks and regard,
madhoriya
Remember that you can call a constructor in an immediate superclass using the super keyword. So basically a constructor in an abstract class is invoked from extending classes' constructors. Note that public constructors in abstract class are not needed since only extending classes can access them
Jul 25 '07 #49
madhoriya22
252 100+
Remember that you can call a constructor in an immediate superclass using the super keyword. So basically a constructor in an abstract class is invoked from extending classes' constructors. Note that public constructors in abstract class are not needed since only extending classes can access them
Thanks for ur suggestions......but still I am trying to understand it......I vil catch u later... If I have another doubts.

What happen to more discussions in free java classes.....eagerly waiting for that....

Thanks and regards,
madhoriya
Jul 25 '07 #50

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: Ravi Tallury | last post by:
Hi We are having issues with our application, certain portions of it stop responding while the rest of the application is fine. I am attaching the Java Core dump. If someone can let me know what...
2
by: Oliver Plohmann | last post by:
Hello! In JDK1.5 Sun has introduced autoboxing. The user does not need to convert an instance of Integer into an int herself anymore when she wants to do arithmetic operations with the int. The...
20
by: Ilias Lazaridis | last post by:
" A cooperation between Sun Microsystems and IBM&Co. in conjunction with liberal & high evolutive communities would result in an nearly unbeatable programming platform. My evaluation has shown:...
25
by: Digital Puer | last post by:
I'm looking at some software development jobs whose listings require C++ experience. My history is that I have a strong C background, and a few years of C++ from undergrad classes. I've been...
3
by: Peter Bernhardt | last post by:
I'm investigating to what extent .NET can 1) consume Java classes, and 2) be compiled into a Java package to run in a J2EE container. I haven't been able to find much information on this aside...
2
by: Jobs | last post by:
Download the JAVA , .NET and SQL Server interview with answers Download the JAVA , .NET and SQL Server interview sheet and rate yourself. This will help you judge yourself are you really worth of...
5
by: r035198x | last post by:
Setting up. Getting started To get started with java, one must download and install a version of Sun's JDK (Java Development Kit). The newest release at the time of writting this article is...
29
by: s0suk3 | last post by:
Hello, I was hoping to get some opinions on a subject. I've been programming Python for almost two years now. Recently I learned Perl, but frankly I'm not very comfortable with it. Now I want to...
5
by: Daniel | last post by:
Hi all, I have some questions regarding C#. I come from a Java background. I am using .NET 1.1. Please limit your answers to v 1.1, otherwise please state the version to which it applies to. ...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.