Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / March 2007

Tip: Looking for answers? Try searching our database.

JAVA BASICS

Thread view: 
hema - 27 Mar 2007 17:41 GMT
HELLO i am new  to java.please  help  me by clarify  these doubts

1)what  is  COMPILE-TIME TYPE   and  RUN-TIME TYPE?

2)what  are  actions  that  are  done  in  COMPILATIONPROCESS   and
in
RUN-TIME  PROCESS?

2)please  give  detailed  explanation on  MULTITHREADING.

PLEASE  GIVE  ME  INFORMATION  ON  JAVA RESOURCES ON  INTERNET
ESPECIALLY  ABOUT  MULTITHREADING(it  is  very  confuse me)
Oliver Wong - 27 Mar 2007 18:08 GMT
> HELLO i am new  to java.please  help  me by clarify  these doubts
>
> 1)what  is  COMPILE-TIME TYPE   and  RUN-TIME TYPE?

   They are terms I'd rather avoid using. Compile-time type probably
refers to the type of a reference, whereas run-time type probably refers
to the type of an object. The concept that an object might be of a
different type than that of the reference pointing to that object is
something a lot of beginners have trouble with, I find. Consider:

Number foo = new Integer(5);

   Here, we have a reference "foo" whose type is Number, and it points to
an object whose type is Integer. The type of the reference (Number) is
different from the type of the object (Integer).

> 2)what  are  actions  that  are  done  in  COMPILATIONPROCESS   and
> in
> RUN-TIME  PROCESS?

   Well... compilation occurs during the "compilation process" and
running-the-program occurs during "run-time process". This is a pretty
open-ended question, and I bet you could fill 4 books with all the
possible things that could be done during compilation and runtime (by
investigating the internals of various compilers and JVMs). I won't bother
going that detailed.

> 2)please  give  detailed  explanation on  MULTITHREADING.
>
> PLEASE  GIVE  ME  INFORMATION  ON  JAVA RESOURCES ON  INTERNET
> ESPECIALLY  ABOUT  MULTITHREADING(it  is  very  confuse me)

See:
http://java.sun.com/docs/books/tutorial/essential/concurrency/

You may also be interested in:
http://www.cs.indiana.edu/docproject/zen/zen-1.0_6.html#SEC56

   - Oliver
Lew - 27 Mar 2007 18:12 GMT
> HELLO i am new  to java.please  help  me by clarify  these doubts
>
[quoted text clipped - 8 lines]
> PLEASE  GIVE  ME  INFORMATION  ON  JAVA RESOURCES ON  INTERNET
> ESPECIALLY  ABOUT  MULTITHREADING(it  is  very  confuse me)

Please avoid USING ALL CAPITAL LETTERS - it gives the impression of screaming.
The proper use of capital letters is to use an upper-case letter as the first
letter of the first word of a sentence, as the first letter of proper nouns
and as each letter within most acronyms.

1)
Compile-time type is the declared type of a variable, e.g.,

List <String> strings;

At compile time the type is known to be 'List <String>'.

If you assign a particular List to that variable:

strings = new ArrayList <String> ();

then at run time, which is when the assignment happens, the run-time type of
the object is ArrayList<String>, but the variable 'strings' still has its
compile-time type of List<String>.

2)
<http://java.sun.com/docs/books/tutorial/essential/concurrency/>

You should be in the habit of looking to Sun's tutorials as a first source for
most things. After that, GIYF.

-- Lew


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.