Posts belonging to Category 'Java Programming'

Java Advanced Imaging API: A Tutorial

In spite of the existence of several image processing softwares with many image processing functions, tailored for several different uses, there is often the need for implementa- tionofspecific algorithms which are not available on those softwares-for example, a user may want to implement his/her own image classification or filtering algorithm or tweak some already implemented algorithm parameters. (more…)

Concepts in Programming LanguagesLecture 8: Java and C

How did we get here? •This lecture: design of Java and C# –Origins –Evolution –Influences •Focus on C# –You know Java –I know C# –Lots of interesting features in upcoming C# 3.0 Java: origins •Sun’s “Oak” project (1991): a language for programming consumer electronic devices •Didn’t take off, but formed basis for Java (1995), a language for the web –Java Virtual Machine was integrated in Sun’s HotJavaweb browser; Netscape and Microsoft followed (more…)

Simple Java Programming

Computational recipes are expressed by writing programs in a programming language. In this chapter, we will explore how some very simple programs can be expressed in Java. In the context of these programs, we will get our rst glimpse of how Java programs are structured and how such programs are executed. In subsequent chapters, we will study the structure and execution of Java programs in much (more…)

Object Oriented Programming with Java: Essentials and Applications

Recent advances in Internet and Web are changing the way we conduct business, manage our life, and interact among ourselves as a society. They have made the world a global village for information exchange and service delivery. However, developing software systems and applications for these environments continues to be a complex and challenging task. In addition, the cost of software maintenance (more…)

Java Program Verification via a JVM Deep Embedding in ACL2

Abstract. In this paper, we show that one can “deep-embed” the Java bytecode language, a fairly complicated language with a rich semantics, into the first order logic of ACL2 by modeling a realistic JVM. We show that with proper support from a semi-automatic theorem prover in that logic, one can reason about the correctness of Java programs. This reasoning can be done in a direct and (more…)

Techniques of Java Programming: Reflection

1 Introduction In Object-Oriented Programming, reflection is the mechanism for discovering data about the program as it runs and use that data to adapt the behavior accordingly. Introspection allows to discover data. Full reflection is allowing richer features: like reflexive calls and potentially dynamic code modification. In Java, the possibilites for reflection are limited to introspection (more…)

Getting started with Java programming in Linux

1 Setting up your Java environment • The Java Development Kit installed on the student PCs at ITU is Suns jdk1.5.0 01. • Setting your PATH: Check if the ”javac” from Suns JDK is already in your PATH: $ which javac If the output is either /usr/java/jdk1.5.0_01 /bin/javac or /usr/java/jdk/bin/javac your PATH is already correct. If not, open the file called ”.bashrc” in your home directory with a text editor, and (more…)

Specifying Multithreaded Java Semantics for Program Verification

ABSTRACT The Java programming language supports multithreading where the threads interact among themselves via read/write of shared data. Most current work on multithreaded Java program veri cation assumes a model of execution that is based on interleaving of the operations of the individual threads. However, the Java language speci cation (which any implementations of Java multithreading (more…)

Mechanisms for secure modular programming in Java

SUMMARY We present a new module system for Java that improves upon many of the deficiencies of the Java package system and gives the programmer more control over dynamic linking.Our module system provides explicit interfaces, multiple views of modules based on hierarchical nesting and more flexible name-space management than the Java package system. Relationships between modules are explicitly (more…)

Object Oriented Programming and Java

Structured Programming • Back in the “old days” we had Structured Programming: – data was separate from code. – programmer is responsible for organizing everything in to logical units of code/data. – no help from the compiler/language for enforcing modularity, OOP to the rescue • Keep data near the relevant code. • Provide a nice packaging mechanism for related code. • Model the world as objects. • objects can send “messages” to each other. An Object • Collection of: (more…)