· JRE (Java Runtime Environment)
The J2SE(TM) Runtime Environment (JRE) is intended for software developers and vendors to redistribute with their applications.
The J2SE Runtime Environment contains the Java virtual machine, runtime class libraries, and Java application launcher that are necessary to run programs written in the Java programming language. It is not a development environment and does not contain development tools such as compilers or debuggers.
Runtime Environment
To run your application, a user needs the J2SE Runtime Environment, which is freely available from Sun. Or, you can redistribute the J2SE Runtime Environment for free with your application, according to the terms of the Runtime Environment's license.
The final step in the deployment process occurs when the software is installed on individual user system. Installation consists of copying software onto the user's system, then configuring the user's system to support that software. You should ensure that your installation procedure does not overwrite existing JRE installations, as they may be required by other applications.
Required vs. Optional Files
The files that make up the J2SE Runtime Environment are divided into two categories: required and optional. Optional files may be excluded from redistributions of the J2SE Runtime Environment at the licensee's discretion. The following section contains a list of the files and directories that may optionally be omitted from redistributions with the J2SE Runtime Environment. All files not in these lists of optional files must be included in redistributions of the runtime environment.
Optional Files and Directories
The following files may be optionally excluded from redistributions. These files are located in the jre1.5.0 directory, where is the update version number. Solaris and Linux filenames and separators are shown. Windows executables have the ".exe" suffix. Corresponding files with _g in name can also be excluded.
· Apache Tomcat
Apache Tomcat (or Jakarta Tomcat or simply Tomcat) is an open source servlet container developed by the Apache Software Foundation (ASF). Tomcat implements the Java Servlet and the JavaServer Pages (JSP) specifications from Sun Microsystems, and provides a "pure Java" HTTP web server environment for Java code to run.[4]
Tomcat should not be confused with the Apache web server, which is a C implementation of an HTTP web server; these two web servers are not bundled together. Apache Tomcat includes tools for configuration and management, but can also be configured by editing XML configuration files. Apache Tomcat is an open source software implementation of the Java Servlet and JavaServer Pages technologies. The Java Servlet and JavaServer Pages specifications are developed under the Java Community Process.
Apache Tomcat is developed in an open and participatory environment and released under the Apache License version 2. Apache Tomcat is intended to be a collaboration of the best-of-breed developers from around the world. We invite you to participate in this open development project. Apache Tomcat powers numerous large-scale, mission-critical web applications across a diverse range of industries and organizations.
· HTML (Hyper Text Markup Language)
Introduction:
· HTML is a language for describing web pages.
· HTML stands for Hyper Text Markup Language
· HTML is not a programming language, it is a markup language A markup language is a set of markup tags
· HTML uses markup tags to describe web pages.
HTML Tags
· HTML markup tags are usually called HTML tags.
· HTML tags are keywords surrounded by angle brackets like
· HTML tags normally come in pairs like and
· The first tag in a pair is the start tag, the second tag is the end tag.
· Start and end tags are also called opening tags and closing tags.
· CSS (Cascading Style Sheets)
Introduction
· CSS stands for Cascading Style Sheets.
· Styles define how to display HTML elements.
· Styles were added to HTML 4.0 to solve a problem.
· External Style Sheets can save a lot of work.
· External Style Sheets are stored in CSS files.
When tags like , and color attributes were added to the HTML 3.2 specification, it started a nightmare for web developers. Development of large web sites, where fonts and color information were added to every single page, became a long and expensive process. To solve this problem, the World Wide Web Consortium (W3C) created CSS.In HTML 4.0, all formatting could be removed from the HTML document, and stored in a separate CSS file. All browsers support CSS today.[5]
· Java Script
Introduction
JavaScript is the most popular scripting language on the internet, and works in all major browsers, such as Internet Explorer, Firefox, Chrome, Opera, and Safari.
· JavaScript was designed to add interactivity to HTML pages.
· JavaScript is a scripting language.
· A scripting language is a lightweight programming language.
· JavaScript is usually embedded directly into HTML pages.
· JavaScript is an interpreted language (means that scripts execute without preliminary compilation).
· Everyone can use JavaScript without purchasing a license.
What can a JavaScript do?
· JavaScript gives HTML designers a programming tool - HTML authors are normally not programmers, but JavaScript is a scripting language with a very simple syntax! Almost anyone can put small "snippets" of code into their HTML pages.
· JavaScript can put dynamic text into an HTML page - A JavaScript statement like this: document.write("
" + name + "
") can write a variable text into an HTML page. · JavaScript can react to events - A JavaScript can be set to execute when something happens, like when a page has finished loading or when a user clicks on an HTML element.
· JavaScript can read and write HTML elements - A JavaScript can read and change the content of an HTML element
· JavaScript can be used to validate data - A JavaScript can be used to validate form data before it is submitted to a server. This saves the server from extra processing
· JavaScript can be used to detect the visitor's browser - A JavaScript can be used to detect the visitor's browser, and - depending on the browser - load another page specifically designed for that browser
· JavaScript can be used to create cookies - A JavaScript can be used to store and retrieve information on the visitor's computer.
· Mysql
Introduction
MySQL is a relational database management system (RDBMS) that runs as a server providing multi-user access to a number of databases. The MySQL development project has made its source code available under the terms of the GNU General Public License, as well as under a variety of proprietary agreements. MySQL is owned and sponsored by a single for-profit firm, the Swedish company MySQL AB, now owned by Sun Microsystems, a subsidiary of Oracle Corporation. Members of the MySQL community have created several forks such as Drizzle and MariaDB. Both forks were in progress before the Oracle acquisition (Drizzle was announced 8 months before the Sun acquisition).
Creating Tables
To create table we use the CREATE TABLE statement. The usual form of this statement is:[6]
CREATE TABLE [IF NOT EXISTS] table_name(
column_list
) type=table_type
MySQL supports IF NOT EXISTS after CREATE TABLE statement to prevent you from error to create table which already exists on the database server. table_name is the name of table you would like to create. After that, you can define a set of columns which is usually in this form: column_name data_type(size) [NOT] NULL. And finally, you can specify the storage engine type you prefer to use for the table. MySQL supports various storage engines such as InnoDB, MyISAM... If you don't explicit declare storage engine type, MySQL will use MyISAM by default.
In our classicmodels sample database, to create employees table we can apply the statement above as follows:
CREATE TABLE employees ( employeeNumber int(11) NOT NULL,
lastName varchar(50) NOT NULL,
firstName varchar(50) NOT NULL,
extension varchar(10) NOT NULL,
email varchar(100) NOT NULL, 0);
Showing and Describing Tables in a Database
In order to show all tables in a database you use SHOW TABLES statment, the server will returns all tables name of the current selected database you work with.
Selecting Data with SQL
SQL IN allows you to select values which match any one of a list of values. The usage of SQL IN is as follows:
SELECT column_list
FROM table_name
WHERE column IN ("list_item1","list_item2"…)
The column in WHERE clause does not need to be in column_list you selected, but it has to be a column in the table table_name. If the list has more than one value, each item has to be separated by a comma.
· Java Database Connectivity (JDBC)
The Java Database Connectivity (JDBC) API is the industry standard for database-independent connectivity between the Java programming language and a wide range of databases – SQL databases and other tabular data sources, such as spreadsheets or flat files. The JDBC API provides a call-level API for SQL-based database access.
JDBC driver types
JDBC drivers are divided into four types or levels. Each type defines a JDBC driver implementation with increasingly higher levels of platform independence, performance, and deployment administration. The four types are:
- Type 1: JDBC-ODBC Bridge
- Type 2: Native-API/partly Java driver
- Type 3: Net-protocol/all-Java driver
- Type 4: Native-protocol/all-Java driver
Type 1 Driver - JDBC-ODBC bridge
The JDBC type 1 driver, also known as the JDBC-ODBC bridge, is a database driver implementation that employs the ODBC driver to connect to the database. The driver converts JDBC method calls into ODBC function calls.
Functions
- Translates query obtained by JDBC into corresponding ODBC query, which is then handled by the ODBC driver.
- Sun provides a JDBC-ODBC Bridge driver. sun.jdbc.odbc.JdbcOdbcDriver. This driver is native code and not Java, and is closed source.
- Client -> JDBC Driver -> ODBC Driver -> Database
- There is some overhead associated with the translation work to go from JDBC to ODBC.
Advantages
- Almost any database for which ODBC driver is installed, can be accessed.
- A type 1 driver is easy to install.
Disadvantages
- Performance overhead since the calls have to go through the JDBC overhead bridge to the ODBC driver, then to the native db connectivity interface.
- The ODBC driver needs to be installed on the client machine.
- Considering the client-side software needed, this is not suitable for applets.