CS 126 Lecture S2: Introduction To Java Applets: Outline
CS 126 Lecture S2: Introduction To Java Applets: Outline
Outline
• Introductions
• Your first applet and more tools of trade
• Life cycle of an applet
• Simple drawing and events
• Conclusions
The “Truth”
• “KISS”
- Large number of complicated features of C++ gone
- The language is incredibly small
- Flip side: huge number of libraries and you can’t be a serious
Java programmer without knowing a lot about them
• “Modern”
- Garbage collection, strongly typed, exceptions, support for
multi-threading and networking
- Flip side: ideas have been around in the research community
for ages: Modula-3, Smalltalk, Lisp, C++, Object C
• “Secure”
- A nice three-tier protection system: verifier, class loader, and
security manager.
- Can reason about it formally
- Flip side: bugs
CS126 21-11 Randy Wang
The “Truth” (cont.)
• “Productive”
- Much less debugging headaches: no pointer probs, exceptions
- Stealing has never been easier: the net, portability, reusability
- Excellent documentation
- Large and growing body of libraries to help: utilities, media,
GUI, networking, threads, databases, cryptogaphy...
- Flip side: versions, large libraries
• “Slow”
- Interpreted, too many tiny objects and methods
- Flip side: just-in-time compiling can make things almost as
fast as native code
• “Hype”
- Important for momentum which translates into community
expertise and support, applications, tools, and libraries
- Flip side: hasty dicision-making to feed the frenzy
• Only game in town?
- Unprecedented roles for scripting languages on the net
CS126 21-12 Randy Wang