If you belive yourself, anything is possible.
--Your friends at LectureNotes

Note for Advanced Java and J2EE - j2ee By vtu rangers

  • Advanced Java and J2EE - j2ee
  • Note
  • Jawaharlal Nehru Technological University Anantapur (JNTU) College of Engineering (CEP), Pulivendula, Pulivendula, Andhra Pradesh, India - JNTUACEP
  • Computer Science Engineering
  • 14 Topics
  • 326 Offline Downloads
  • Uploaded 1 year ago
0 User(s)
Download PDFOrder Printed Copy

Share it with your friends

Leave your Comments

Text from page-1

Advanced Java and J2EE 15CS553 ADVANCED JAVA and J2EE Subject Code: 15CS553 Hours/Week: 3 Total Hours: 40 MODULE-I IA Marks: 20 Exam Hours: 3 Exam Marks: 80 8 Hours Enumerations, Autoboxing and Annotations(metadata): Enumerations, Enumeration fundamentals, the values() and valueOf() Methods, java enumerations are class types, enumerations Inherits Enum, example, type wrappers, Autoboxing, Autoboxing and Methods, Autoboxing/Unboxing occurs in Expressions, Autoboxing/Unboxing, Boolean and character values, Autoboxing/Unboxing helps prevent errors, A word of Warning. Annotations, Annotation basics, specifying retention policy, Obtaining Annotations at runtime by use of reflection, Annotated element Interface, Using Default values, Marker Annotations, Single Member annotations, Built-In annotations. MODULE-II 8 Hours The collections and Framework: Collections Overview, Recent Changes to Collections, The Collection Interfaces, The Collection Classes, Accessing a collection Via an Iterator, Storing User Defined Classes in Collections, The Random Access Interface, Working With Maps, Comparators, The Collection Algorithms, Why Generic Collections?, The legacy Classes and Interfaces, Parting Thoughts on Collections. MODULE-III 8 Hours String Handling :The String Constructors, String Length, Special String Operations, String Literals, String Concatenation, String Concatenation with Other Data Types, String Conversion and toString( ) Character Extraction, charAt( ), getChars( ), getBytes( ) toCharArray(), String Comparison, equals( ) and equalsIgnoreCase( ), regionMatches( ) startsWith( ) and endsWith( ), equals() Versus == , compareTo( ) Searching Strings, Modifying a String, substring( ), concat( ), replace( ), trim( ), Data Conversion Using valueOf( ), Changing the Case of Characters Within a String, Additional String Methods, StringBuffer , StringBuffer Constructors, length( ) and capacity( ), ensureCapacity( ), setLength( ), charAt( ) and setCharAt( ), getChars( ),append( ), insert( ), reverse(), delete( ) and deleteCharAt( ), replace( ), substring( ), Additional StringBuffer Methods, StringBuilder MODULE-IV 8 Hours Servlet: Background; The Life Cycle of a Servlet; Using Tomcat for Servlet Development; A simple Servlet; The Servlet API; The Javax.servlet Package; Reading Servlet Parameter; The Javax.servlet.http package; Handling HTTP Requests and Responses; Using Cookies; Session Tracking. Java Server Pages (JSP): JSP, JSP Tags, Tomcat, Request String, User Sessions, Cookies, Session Objects MODULE-V Dept. of CSE, SJBIT 8 Hours Page i

Text from page-2

Advanced Java and J2EE 15CS553 The Concept of JDBC; JDBC Driver Types; JDBC Packages; A Brief Overview of the JDBC process; Database Connection; Associating the JDBC/ODBC Bridge with the Database; Statement Objects; ResultSet; Transaction Processing; Metadata, Data types; Exceptions. Reference / Text Book Details Sl.No. Title of Book Author Publication Edition Tata McGraw Hill 7th/9th J2EE The Complete Reference Jim Keogh Tata McGraw Hill 2007 3 Introduction to JAVA Programming Y. Daniel Liang Pearson Education, 2007 7th 4 The J2EE Tutorial Stephanie Bodoff Pearson Education, 2004 2n d 5 Advanced Programming 1 JAVA The Complete Reference 2 Herbert Schildt JAVA Uttam K Roy Oxford University Press 2015 . Dept. of CSE, SJBIT Page ii

Text from page-3

Advanced Java and J2EE SL No Table of Contents Module Description 15CS553 Page No 1 Module 1 – Enumeration, AutoBoxing and Annotations 1-23 2 Module 2 – Collection Framework 24-57 3 Module 3 – String Methods 58-119 4 Module 4 – Servlets and JSP 120-149 5 Module 5 – JDBC Methods 150-166 Dept. of CSE, SJBIT Page iii

Text from page-4

Advanced Java and J2EE Module – 1 Enumerations, Autoboxing and Annotations 15CS553 Enumerations Enumerations was added to Java language in JDK5. Enumeration means a list of named constant. In Java, enumeration defines a class type. An Enumeration can have constructors, methods and instance variables. It is created using enum keyword. Each enumeration constant is public, static and final by default. Even though enumeration defines a class type and have constructors, you do not instantiate an enum using new. Enumeration variables are used and declared in much a same way as you do a primitive variable. How to Define and Use an Enumeration 1. An enumeration can be defined simply by creating a list of enum variable. Let us take an example for list of Subject variable, with different subjects in the list. enum Subject //Enumeration defined { Java, Cpp, C, Dbms } 2. Identifiers Java, Cpp, C and Dbms are called enumeration constants. These are public, static and final by default. 3. Variables of Enumeration can be defined directly without any new keyword. Subject sub; 4. Variables of Enumeration type can have only enumeration constants as value. We define an enum variable as enum_variable = enum_type.enum_constant; sub = Subject.Java; 5. Two enumeration constants can be compared for equality by using the = = relational operator. Example: if(sub == Subject.Java) { ... } Dept. of CSE, SJBIT Page 1

Lecture Notes