java - Intro to Java for ECS 160 Stoney Jackson...

Info iconThis preview shows pages 1–12. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Intro to Java for ECS 160 Stoney Jackson jacksoni@cs.ucdavis.edu wwwcsif.cs.ucdavis.edu/~jacksoni Whats the first question youve got to ask about a language named Java? 2 Can you make coffee with it? 3 It was meant to!! A programming language for appliances! 4 Java Virtual Machine Must Run on Any Architecture Program in Java Java Compiler Java Bytecode Java Virtual Machine WRITE ONCE, RUN ANYWHERE! debug pretty portable 5 Doesnt Make Coffee Yet 6 So Whats Java Good For? Web applications! Java Applet Server Java Applet 7 Java on the Web: Java Applets Clients download applets via Web browser Browser runs applet in a Java Virtual Machine (JVM) Interactive web, security, and client consistency Slow to download, inconsistent VMs (besides, flash won this war) Applet Client Server 8 Java on the Web: J2EE Thin clients (minimize download) Java all server side THIS IS WHAT YOULL BE DOING!! Client Server JSPs Servlets EJB JDBC 9 The Java programming environment Compared to C++:  no header files, macros, pointers and references, unions, operator overloading, templates, etc. Object-orientation : Classes + Inheritance Distributed : RMI, Servlet, Distributed object programming. Robust : Strong typing + no pointer + garbage collection Secure : Type-safety + access control Architecture neutral : architecture neutral representation Portable Interpreted  High performance through Just in time compilation + runtime modification of code Multi-threaded 10 Java Features Well defined primitive data types: int, float, double, char, etc.  int 4 bytes [2,147,648, 2,147,483,647] Control statements similar to C++: if-then-else, switch, while, for Interfaces Exceptions Concurrency Packages Name spaces Reflection Applet model 11 The Java programming environment Java programming language specification  Syntax of Java programs  Defines different constructs and their semantics Java byte code : Intermediate representation for Java programs Java compiler : Transform Java programs into Java byte code Java interpreter : Read programs written in Java byte code and execute them Java virtual machine : Runtime system that provides various services to running programs Java programming environment : Set of libraries that provide services such as GUI, data structures,etc....
View Full Document

Page1 / 38

java - Intro to Java for ECS 160 Stoney Jackson...

This preview shows document pages 1 - 12. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online