How advanced is java 1.6 with respect to java 1.1 ?

Discussion in 'Java' started by broli, Jan 10, 2009.

  1. broli

    broli Guest

    I've learned java 1.1 using a relatively old video tutorial and
    realized it only later.

    Is java 1.1 similar to java 1.6 or is it radically different ?

    And if its similar, what additional features do I need to learn ?
    broli, Jan 10, 2009
    #1
    1. Advertising

  2. broli

    Arne Vajhøj Guest

    broli wrote:
    > I've learned java 1.1 using a relatively old video tutorial and
    > realized it only later.
    >
    > Is java 1.1 similar to java 1.6 or is it radically different ?
    >
    > And if its similar, what additional features do I need to learn ?


    Everything you have learned is still valid (except for a few very
    obscure points).

    But there has added some things to the Java language.

    And the Java library is much much bigger.

    So you will need to learn some more before you are
    uptodate on Java 1.6.

    Arne
    Arne Vajhøj, Jan 10, 2009
    #2
    1. Advertising

  3. Arne Vajhøj wrote:
    > broli wrote:
    >> I've learned java 1.1 using a relatively old video tutorial and
    >> realized it only later.
    >>
    >> Is java 1.1 similar to java 1.6 or is it radically different ?
    >>
    >> And if its similar, what additional features do I need to learn ?

    >
    > Everything you have learned is still valid (except for a few very
    > obscure points).
    >
    > But there has added some things to the Java language.


    The biggest ones being inner classes and generics.
    Mike Schilling, Jan 10, 2009
    #3
  4. broli

    Lew Guest

    broli wrote:
    >> I've learned java [sic] 1.1 using a relatively old video tutorial and
    >> realized it only later.
    >>
    >> Is java [sic] 1.1 similar to java [sic] 1.6 or is it radically different ?
    >>
    >> And if its similar, what additional features do I need to learn ?


    Arne Vajhøj wrote:
    > Everything you have learned is still valid (except for a few very
    > obscure points).
    >
    > But there has added some things to the Java language.
    >
    > And the Java library is much much bigger.
    >
    > So you will need to learn some more before you are
    > uptodate on Java 1.6.


    A lot more.

    The Collections framework, 'assert', generics, the new memory model,
    additional run-time options (e.g., for the garbage collector), the 'for-each'
    loop construct, and a number of stylistic and idiomatic changes, plus
    gazillions of new APIs (NIO and java.util.concurrent to name two). And so
    much more.

    For God's sake, don't use java.util.Vector or java.util.Hashtable any more.

    Synchronization is now much, much less expensive. Allocation and garbage
    collection are now much, much faster. Swing has come into existence, and been
    infinitely improved. Java Enterprise Edition has appeared, with many good
    implementations, some of them open source.

    There is a ton of documentation on these issues and more. java.sun.com and
    http://www.ibm.com/developerworks/java are good sources for tutorials and
    articles. Read and study Joshua Bloch's /Effective Java/ and Brian Goetz's
    /Java Concurrency in Practice/. For starters.

    --
    Lew
    Lew, Jan 10, 2009
    #4
  5. broli

    Daniel Pitts Guest

    broli wrote:
    > I've learned java 1.1 using a relatively old video tutorial and
    > realized it only later.
    >
    > Is java 1.1 similar to java 1.6 or is it radically different ?
    >
    > And if its similar, what additional features do I need to learn ?


    Java 1.1 programs will work in Java 1.6, but you will miss a *lot* of
    powerful features/libraries/speed/etc... that has been added over the years.

    Note, Java 1.1 was released over a decade ago, and Java has been almost
    constantly improving in the mean time.
    <http://java.sun.com/j2se/codenames.html>


    --
    Daniel Pitts' Tech Blog: <http://virtualinfinity.net/wordpress/>
    Daniel Pitts, Jan 10, 2009
    #5
  6. broli

    broli Guest

    Alright, then in that case I will switch to a more recent book.

    It seems the only things similar is the basic syntax, control loops
    etc.
    broli, Jan 10, 2009
    #6
  7. On Jan 10, 12:32 pm, broli <> wrote:
    > Alright, then in that case I will switch to a more recent book.


    For the API JavaDocs, bookmark this..
    <http://java.sun.com/javase/6/docs/api/overview-summary.html>

    Or better still, download them..
    <http://java.sun.com/javase/downloads/index.jsp#docs>

    --
    Andrew Thompson
    http://pscode.org/
    Andrew Thompson, Jan 10, 2009
    #7
  8. Mike Schilling wrote:
    > Arne Vajhøj wrote:
    >> broli wrote:
    >>> I've learned java 1.1 using a relatively old video tutorial and
    >>> realized it only later.
    >>>
    >>> Is java 1.1 similar to java 1.6 or is it radically different ?
    >>>
    >>> And if its similar, what additional features do I need to learn ?

    >> Everything you have learned is still valid (except for a few very
    >> obscure points).
    >>
    >> But there has added some things to the Java language.

    >
    > The biggest ones being inner classes and generics.
    >
    >


    Inner classes were already in 1.1

    Mark Thornton.
    Mark Thornton, Jan 10, 2009
    #8
  9. broli

    Tom Anderson Guest

    On Fri, 9 Jan 2009, Mike Schilling wrote:

    > Arne Vajhøj wrote:
    >> broli wrote:
    >>> I've learned java 1.1 using a relatively old video tutorial and
    >>> realized it only later.
    >>>
    >>> Is java 1.1 similar to java 1.6 or is it radically different ?
    >>>
    >>> And if its similar, what additional features do I need to learn ?

    >>
    >> Everything you have learned is still valid (except for a few very
    >> obscure points).
    >>
    >> But there has added some things to the Java language.

    >
    > The biggest ones being inner classes and generics.


    I'd say the biggest one is collections. Those came in in 1.2, and made a
    huge difference to everyday programming.

    There were some massive changes on the GUI side around then, too - i don't
    think the basics of AWT changed much from 1.1 to 1.2 (they did from 1.0 to
    1.1), but isn't that when Swing came in?

    tom

    --
    Punk's not sexual, it's just aggression.
    Tom Anderson, Jan 10, 2009
    #9

  10. > For God's sake, don't use java.util.Vector or java.util.Hashtable any more.


    I use java.util.Vector a lot.What's the alternative you suggest?

    Prabesh Shrestha
    prabesh shrestha, Jan 10, 2009
    #10
  11. In article
    <>,
    prabesh shrestha <> wrote:

    > > For God's sake, don't use java.util.Vector or java.util.Hashtable any more.

    >
    > I use java.util.Vector a lot.What's the alternative you suggest?


    When any ordered collection (sequence) that implements the List or Map
    interface will do, select the one that does what you want with the least
    extra baggage. For example, I'd prefer ArrayList to Vector when
    synchronization is not required; I'd prefer LinkedList to Stack and
    HashMap to HashTable for a similar reason. Conversely, I wouldn't use
    ConcurrentSkipListMap when a plain old HashMap is sufficient.

    <http://java.sun.com/javase/6/docs/api/java/util/List.html>
    <http://java.sun.com/javase/6/docs/api/java/util/Map.html>

    --
    John B. Matthews
    trashgod at gmail dot com
    <http://sites.google.com/site/drjohnbmatthews>
    John B. Matthews, Jan 10, 2009
    #11
  12. Mark Thornton wrote:
    > Mike Schilling wrote:
    >> Arne Vajhøj wrote:
    >>> broli wrote:
    >>>> I've learned java 1.1 using a relatively old video tutorial and
    >>>> realized it only later.
    >>>>
    >>>> Is java 1.1 similar to java 1.6 or is it radically different ?
    >>>>
    >>>> And if its similar, what additional features do I need to learn ?
    >>> Everything you have learned is still valid (except for a few very
    >>> obscure points).
    >>>
    >>> But there has added some things to the Java language.

    >>
    >> The biggest ones being inner classes and generics.
    >>
    >>

    >
    > Inner classes were already in 1.1



    Your're right. Generics, then, along with autoboxing and the other 1.5
    changes.
    Mike Schilling, Jan 10, 2009
    #12
  13. broli

    Lew Guest

    Tom Anderson wrote:
    > I'd say the biggest one is collections. Those came in in 1.2, and made a
    > huge difference to everyday programming.
    >
    > There were some massive changes on the GUI side around then, too -
    > don't think the basics of AWT changed much from 1.1 to 1.2 (they did
    > from 1.0 to 1.1), but isn't that when Swing came in?


    <http://en.wikipedia.org/wiki/Java_version_history>

    --
    Lew
    Lew, Jan 10, 2009
    #13
  14. broli

    Lew Guest

    Lew wrote:
    >>> For God's sake, don't use java.util.Vector or java.util.Hashtable any more.


    prabesh shrestha wrote:
    >> I use java.util.Vector a lot.What's the alternative you suggest?


    That class was replaced over *ten* years ago! Why are you still using it?

    John B. Matthews wrote:
    > When any ordered collection (sequence) that implements the List or Map
    > interface will do, select the one that does what you want with the least
    > extra baggage. For example, I'd prefer ArrayList to Vector when
    > synchronization is not required; I'd prefer LinkedList to Stack and
    > HashMap to HashTable for a similar reason. Conversely, I wouldn't use
    > ConcurrentSkipListMap when a plain old HashMap is sufficient.
    >
    > <http://java.sun.com/javase/6/docs/api/java/util/List.html>
    > <http://java.sun.com/javase/6/docs/api/java/util/Map.html>


    Quite in line with the advice to incur "the least extra baggage",
    'Collections.synchronizedList(List)' is better than 'Vector 'and
    'Collections.synchronizedMap(Map)' is better than 'Hashtable'. They don't
    have extraneous methods and related classes that are outside the collections
    framework.

    <http://java.sun.com/javase/6/docs/api/java/util/Collections.html#synchronizedList(java.util.List)>
    <http://java.sun.com/javase/6/docs/api/java/util/Collections.html#synchronizedMap(java.util.Map)>

    'Vector' has methods like 'elementAt()' and helper classes like 'Enumeration'
    that you don't need in original code, and 'Hashtable' also pulls in
    'Enumeration'.

    The Javadocs for 'Stack' tell us:
    > A more complete and consistent set of LIFO stack operations
    > is provided by the Deque interface and its implementations,
    > which should be used in preference to this class.


    See also:
    <http://java.sun.com/javase/6/docs/api/java/util/Collections.html#asLifoQueue(java.util.Deque)>
    <http://java.sun.com/javase/6/docs/api/java/util/concurrent/LinkedBlockingDeque.html>

    There really is no good reason to use those antiquated legacy classes any
    more. Their replacement predates the time when most anybody making money
    writing Java code started doing so.

    --
    Lew
    Lew, Jan 10, 2009
    #14
  15. broli

    Arne Vajhøj Guest

    Tom Anderson wrote:
    > On Fri, 9 Jan 2009, Mike Schilling wrote:
    >> Arne Vajhøj wrote:
    >>> broli wrote:
    >>>> I've learned java 1.1 using a relatively old video tutorial and
    >>>> realized it only later.
    >>>>
    >>>> Is java 1.1 similar to java 1.6 or is it radically different ?
    >>>>
    >>>> And if its similar, what additional features do I need to learn ?
    >>>
    >>> Everything you have learned is still valid (except for a few very
    >>> obscure points).
    >>>
    >>> But there has added some things to the Java language.

    >>
    >> The biggest ones being inner classes and generics.

    >
    > I'd say the biggest one is collections. Those came in in 1.2, and made a
    > huge difference to everyday programming.


    Collection framework came in 1.2, but Vector and Hashtable did exist
    before.

    > There were some massive changes on the GUI side around then, too - i
    > don't think the basics of AWT changed much from 1.1 to 1.2 (they did
    > from 1.0 to 1.1), but isn't that when Swing came in?


    Swing came in 1.2 (I believe it could be used in 1.1 as an extra
    library).

    Arne
    Arne Vajhøj, Jan 10, 2009
    #15
  16. broli

    Arne Vajhøj Guest

    prabesh shrestha wrote:
    >> For God's sake, don't use java.util.Vector or java.util.Hashtable any more.

    >
    > I use java.util.Vector a lot.What's the alternative you suggest?


    java.util.ArrayList

    Arne
    Arne Vajhøj, Jan 10, 2009
    #16
  17. prabesh shrestha wrote:
    >> For God's sake, don't use java.util.Vector or java.util.Hashtable any more.

    >
    > I use java.util.Vector a lot.What's the alternative you suggest?


    It depends. Do you want an O(N) random-access list but O(1) head/tail
    insertion/deletion? Or an O(1) random-access list but O(N) head
    insertion/deletion and O(1) amortized tail insertion/deletion?

    If you read the documentation for java.util.Vector, you'll notice that
    it contains a strong warning to use other collections; the only reason
    it's not deprecated is because non-deprecated APIs have to use it.

    --
    Beware of bugs in the above code; I have only proved it correct, not
    tried it. -- Donald E. Knuth
    Joshua Cranmer, Jan 10, 2009
    #17
  18. broli

    Mark Space Guest

    broli wrote:
    > Alright, then in that case I will switch to a more recent book.
    >
    > It seems the only things similar is the basic syntax, control loops
    > etc.


    Also, you might try the Sun's online tutorial, since that is kept up to
    date.

    <http://java.sun.com/docs/books/tutorial/>
    Mark Space, Jan 10, 2009
    #18
  19. broli

    Tom Anderson Guest

    On Sat, 10 Jan 2009, Arne Vajhøj wrote:

    > Tom Anderson wrote:
    >> On Fri, 9 Jan 2009, Mike Schilling wrote:
    >>> Arne Vajhøj wrote:
    >>>> broli wrote:
    >>>>> I've learned java 1.1 using a relatively old video tutorial and
    >>>>> realized it only later.
    >>>>>
    >>>>> Is java 1.1 similar to java 1.6 or is it radically different ?
    >>>>>
    >>>>> And if its similar, what additional features do I need to learn ?
    >>>>
    >>>> Everything you have learned is still valid (except for a few very
    >>>> obscure points).
    >>>>
    >>>> But there has added some things to the Java language.
    >>>
    >>> The biggest ones being inner classes and generics.

    >>
    >> I'd say the biggest one is collections. Those came in in 1.2, and made a
    >> huge difference to everyday programming.

    >
    > Collection framework came in 1.2, but Vector and Hashtable did exist
    > before.


    True. But collections added loads more stuff, including an Iterator
    interface that wasn't as agonising to use as Enumeration.

    tom

    --
    FREQUENT VIOLENT BLOODY
    Tom Anderson, Jan 10, 2009
    #19
  20. broli

    Roedy Green Guest

    On Fri, 9 Jan 2009 16:32:15 -0800 (PST), broli <>
    wrote, quoted or indirectly quoted someone who said :

    >Is java 1.1 similar to java 1.6 or is it radically different ?
    >
    >And if its similar, what additional features do I need to learn ?


    See http://mindprod.com/jgloss/jdk.html
    for a list of major features added with each version.
    The big advances I would say are

    Collections
    Swing
    Assertions
    for:each
    autoboxing
    Generics
    --
    Roedy Green Canadian Mind Products
    http://mindprod.com
    PM Steven Harper is fixated on the costs of implementing Kyoto, estimated as high as 1% of GDP.
    However, he refuses to consider the costs of not implementing Kyoto which the
    famous economist Nicholas Stern estimated at 5 to 20% of GDP
    Roedy Green, Jan 11, 2009
    #20
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Showjumper
    Replies:
    4
    Views:
    381
    Showjumper
    Jan 24, 2004
  2. John Charlois

    Roedy please respect the netiquette

    John Charlois, Jun 4, 2004, in forum: Java
    Replies:
    83
    Views:
    1,439
    Darryl L. Pierce
    Jun 14, 2004
  3. Soeren Gerlach
    Replies:
    0
    Views:
    428
    Soeren Gerlach
    Jul 15, 2004
  4. Danny
    Replies:
    8
    Views:
    13,948
    brucie
    Jul 17, 2004
  5. Michele Simionato
    Replies:
    1
    Views:
    583
    Lacrima
    Mar 27, 2010
Loading...

Share This Page