6
What to read and What not! – Complete Reference
1 | The History and Evolution of Java |
Java’s Lineage | |
The Birth of Modern Programming: C | |
C++: The Next Step | |
The Stage Is Set for Java | |
The Creation of Java | |
The C# Connection | |
How Java Changed the Internet | |
Java Applets | |
Security | |
Portability | |
Java’s Magic: The Bytecode | |
Servlets: Java on the Server Side | |
The Java Buzzwords | |
Simple | |
Object-Oriented | |
Robust | |
Multithreaded | |
Architecture-Neutral | |
Interpreted and High Performance | |
Distributed | |
Dynamic | |
The Evolution of Java | |
Java SE 6 | |
A Culture of Innovation | |
2 | An Overview of Java |
Object-Oriented Programming | |
Two Paradigms | |
Abstraction | |
The Three OOP Principles | |
A First Simple Program | |
Entering the Program | |
Compiling the Program | |
A Closer Look at the First Sample Program | |
A Second Short Program | |
Two Control Statements | |
The if Statement | |
The for Loop | |
Using Blocks of Code | |
Lexical Issues | |
Whitespace | |
Identifiers | |
Literals | |
Comments | |
Separators | |
The Java Keywords | |
The Java Class Libraries | |
3 | Data Types, Variables, and Arrays |
Java Is a Strongly Typed Language | |
The Primitive Types | |
Integers | |
byte | |
short | |
int | |
long | |
Floating-Point Types | |
float | |
double | |
Characters | |
Booleans | |
A Closer Look at Literals | |
Integer Literals | |
Floating-Point Literals | |
Boolean Literals | |
Character Literals | |
String Literals | |
Variables | |
Declaring a Variable | |
Dynamic Initialization | |
The Scope and Lifetime of Variables | |
Type Conversion and Casting | |
Java’s Automatic Conversions | |
Casting Incompatible Types | |
Automatic Type Promotion in Expressions | |
The Type Promotion Rules | |
Arrays | |
One-Dimensional Arrays | |
Multidimensional Arrays | |
Alternative Array Declaration Syntax | |
A Few Words About Strings | |
A Note to C/C++ Programmers About Pointers | |
4 | Operators |
Arithmetic Operators | |
The Basic Arithmetic Operators | |
The Modulus Operator | |
Arithmetic Compound Assignment Operators | |
Increment and Decrement | |
The Bitwise Operators | |
The Bitwise Logical Operators | |
The Left Shift | |
The Right Shift | |
The Unsigned Right Shift | |
Bitwise Operator Compound Assignments | |
Relational Operators | |
Boolean Logical Operators | |
Short-Circuit Logical Operators | |
The Assignment Operator | |
The ? Operator | |
Operator Precedence | |
Using Parentheses | |
5 | Control Statements |
Java’s Selection Statements | |
if | |
switch | |
Iteration Statements | |
while | |
do-while | |
for | |
The For-Each Version of the for Loop | |
Nested Loops | |
Jump Statements | |
Using break | |
Using continue | |
return | |
6 | Introducing Classes |
Class Fundamentals | |
The General Form of a Class | |
A Simple Class | |
Declaring Objects | |
A Closer Look at new | |
Assigning Object Reference Variables | |
Introducing Methods | |
Adding a Method to the Box Class | |
Returning a Value | |
Adding a Method That Takes Parameters | |
Constructors | |
Parameterized Constructors | |
The this Keyword | |
Instance Variable Hiding | |
Garbage Collection | |
The finalize( ) Method | |
A Stack Class | |
7 | A Closer Look at Methods and Classes |
Overloading Methods | |
Overloading Constructors | |
Using Objects as Parameters | |
A Closer Look at Argument Passing | |
Returning Objects | |
Recursion | |
Introducing Access Control | |
Understanding static | |
Introducing final | |
Arrays Revisited | |
Introducing Nested and Inner Classes | |
Exploring the String Class | |
Using Command-Line Arguments | |
Varargs: Variable-Length Arguments | |
Overloading Vararg Methods | |
Varargs and Ambiguity | |
8 | Inheritance |
Inheritance Basics | |
Member Access and Inheritance | |
A More Practical Example | |
A Superclass Variable Can Reference a Subclass Object | |
Using super | |
Using super to Call Superclass Constructors | |
A Second Use for super | |
Creating a Multilevel Hierarchy | |
When Constructors Are Called | |
Method Overriding | |
Dynamic Method Dispatch | |
Why Overridden Methods? | |
Applying Method Overriding | |
Using Abstract Classes | |
Using final with Inheritance | |
Using final to Prevent Overriding | |
Using final to Prevent Inheritance | |
The Object Class | |
9 | Packages and Interfaces |
Packages | |
Defining a Package | |
Finding Packages and CLASSPATH | |
A Short Package Example | |
Access Protection | |
An Access Example | |
Importing Packages | |
Interfaces | |
Defining an Interface | |
Implementing Interfaces | |
Nested Interfaces | |
Applying Interfaces | |
Variables in Interfaces | |
Interfaces Can Be Extended | |
10 | Exception Handling |
Exception-Handling Fundamentals | |
Exception Types | |
Uncaught Exceptions | |
Using try and catch | |
Displaying a Description of an Exception | |
Multiple catch Clauses | |
Nested try Statements | |
throw | |
throws | |
finally | |
Java’s Built-in Exceptions | |
Creating Your Own Exception Subclasses | |
Chained Exceptions | |
Using Exceptions | |
11 | Multithreaded Programming |
The Java Thread Model | |
Thread Priorities | |
Synchronization | |
Messaging | |
The Thread Class and the Runnable Interface | |
The Main Thread | |
Creating a Thread | |
Implementing Runnable | |
Extending Thread | |
Choosing an Approach | |
Creating Multiple Threads | |
Using isAlive( ) and join( ) | |
Thread Priorities | |
Synchronization | |
Using Synchronized Methods | |
The synchronized Statement | |
Interthread Communication | |
Deadlock | |
Suspending, Resuming, and Stopping Threads | |
The Modern Way of Suspending, Resuming and Stopping Threads | |
Using Multithreading | |
12 | Enumerations, Autoboxing, and Annotations (Metadata) |
Enumerations | |
Enumeration Fundamentals | |
The values( ) and valueOf( ) Methods | |
Java Enumerations Are Class Types | |
Enumerations Inherit Enum | |
Another Enumeration Example | |
Type Wrappers | |
Autoboxing | |
Autoboxing and Methods | |
Autoboxing/Unboxing Occurs in Expressions | |
Autoboxing/Unboxing Boolean and Character Values | |
Autoboxing/Unboxing Helps Prevent Errors | |
AWord of Warning | |
Annotations (Metadata) | |
Annotation Basics | |
Specifying a Retention Policy | |
Obtaining Annotations at Run Time by Use of Reflection | |
The AnnotatedElement Interface | |
Using Default Values | |
Marker Annotations | |
Single-Member Annotations | |
The Built-In Annotations | |
Some Restrictions | |
13 | I/O, Applets, and Other Topics |
I/O Basics | |
Streams | |
Byte Streams and Character Streams | |
The Predefined Streams | |
Reading Console Input | |
Reading Characters | |
Reading Strings | |
Writing Console Output | |
The PrintWriter Class | |
Reading and Writing Files | |
Applet Fundamentals | |
The transient and volatile Modifiers | |
Using instanceof | |
strictfp | |
Native Methods | |
Problems with Native Methods | |
Using assert | |
Assertion Enabling and Disabling Options | |
Static Import | |
Invoking Overloaded Constructors Through this( ) | |
14 | Generics |
What Are Generics? | |
A Simple Generics Example | |
Generics Work Only with Objects | |
Generic Types Differ Based on Their Type Arguments | |
How Generics Improve Type Safety | |
A Generic Class with Two Type Parameters | |
The General Form of a Generic Class | |
Bounded Types | |
Using Wildcard Arguments | |
Bounded Wildcards | |
Creating a Generic Method | |
Generic Constructors | |
Generic Interfaces | |
Raw Types and Legacy Code | |
Generic Class Hierarchies | |
Using a Generic Superclass | |
A Generic Subclass | |
Run-Time Type ComparisonsWithin a Generic Hierarchy | |
Casting | |
Overriding Methods in a Generic Class | |
Erasure | |
Bridge Methods | |
Ambiguity Errors | |
Some Generic Restrictions | |
Type Parameters Can Be Instantiated | |
Restrictions on Static Members | |
Generic Array Restrictions | |
Generic Exception Restriction | |
Final Thoughts on Generics | |
15 | 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 | |
16 | Exploring java |
Primitive Type Wrappers | |
Number | |
Double and Float | |
Byte, Short, Integer, and Long | |
Character | |
Recent Additions to Character for Unicode Code | |
Point Support | |
Boolean | |
Void | |
Process | |
Runtime | |
Memory Management | |
Executing Other Programs | |
ProcessBuilder | |
System | |
Using currentTimeMillis( ) to Time Program Execution | |
Using arraycopy( ) | |
Environment Properties | |
Object | |
Using clone( ) and the Cloneable Interface | |
Class | |
ClassLoader | |
Math | |
Transcendental Functions | |
Exponential Functions | |
Rounding Functions | |
Miscellaneous Math Methods | |
StrictMath | |
Compiler | |
Thread, ThreadGroup, and Runnable | |
The Runnable Interface | |
Thread | |
ThreadGroup | |
ThreadLocal and InheritableThreadLocal | |
Package | |
RuntimePermission | |
Throwable | |
SecurityManager | |
StackTraceElement | |
Enum | |
The CharSequence Interface | |
The Comparable Interface | |
The Appendable Interface | |
The Iterable Interface | |
The Readable Interface | |
17 | java Collection Framework |
Recent Changes to Collections | |
Generics Fundamentally Change the Collections | |
Framework | |
Autoboxing Facilitates the Use of Primitive Types | |
The For-Each Style for Loop | |
The Collection Interfaces | |
The Collection Interface | |
The List Interface | |
The Set Interface | |
The SortedSet Interface | |
The NavigableSet Interface | |
The Queue Interface | |
The Deque Interface | |
The Collection Classes | |
The ArrayList Class | |
The LinkedList Class | |
The HashSet Class | |
The LinkedHashSet Class | |
The TreeSet Class | |
The PriorityQueue Class | |
The ArrayDeque Class | |
The EnumSet Class | |
Accessing a Collection via an Iterator | |
Using an Iterator | |
The For-Each Alternative to Iterators | |
Storing User-Defined Classes in Collections | |
The RandomAccess Interface | |
Working with Maps | |
The Map Interfaces | |
The NavigableMap Interface | |
The Map Classes | |
Comparators | |
Using a Comparator | |
The Collection Algorithms | |
Arrays | |
Why Generic Collections? | |
The Legacy Classes and Interfaces | |
The Enumeration Interface | |
Vector | |
Stack | |
Dictionary | |
Hashtable | |
Properties | |
Using store( ) and load( ) | |
Parting Thoughts on Collections | |
18 | java – More Util Classes |
StringTokenizer | |
BitSet | |
Date | |
Calendar | |
GregorianCalendar | |
TimeZone | |
SimpleTimeZone | |
Locale | |
Random | |
Observable | |
The Observer Interface | |
An Observer Example | |
Timer and TimerTask | |
Currency | |
Formatter | |
The Formatter Constructors | |
The Formatter Methods | |
Formatting Basics | |
Formatting Strings and Characters | |
Formatting Numbers | |
Formatting Time and Date | |
The %n and %% Specifiers | |
Specifying a Minimum Field Width | |
Specifying Precision | |
Using the Format Flags | |
Justifying Output | |
The Space, +, 0, and ( Flags | |
The Comma Flag | |
The # Flag | |
The Uppercase Option | |
Using an Argument Index | |
The Java printf( ) Connection | |
Scanner | |
The Scanner Constructors | |
Scanning Basics | |
Some Scanner Examples | |
Setting Delimiters | |
Other Scanner Features | |
The ResourceBundle, ListResourceBundle, | |
andPropertyResourceBundle Classes | |
Miscellaneous Utility Classes and Interfaces | |
19 | Input/Output: Exploring java |
The Java I/O Classes and Interfaces | |
File | |
Directories | |
Using FilenameFilter | |
The listFiles( ) Alternative | |
Creating Directories | |
The Closeable and Flushable Interfaces | |
The Stream Classes | |
The Byte Streams | |
InputStream | |
OutputStream | |
FileInputStream | |
FileOutputStream | |
ByteArrayInputStream | |
ByteArrayOutputStream | |
Filtered Byte Streams | |
Buffered Byte Streams | |
SequenceInputStream | |
PrintStream | |
DataOutputStream and DataInputStream | |
RandomAccessFile | |
The Character Streams | |
Reader | |
Writer | |
FileReader | |
FileWriter | |
CharArrayReader | |
CharArrayWriter | |
BufferedReader | |
BufferedWriter | |
PushbackReader | |
PrintWriter | |
The Console Class | |
Using Stream I/O | |
Improving wc( ) Using a StreamTokenizer | |
Serialization | |
Serializable | |
Externalizable | |
ObjectOutput | |
ObjectOutputStream | |
ObjectInput | |
ObjectInputStream | |
A Serialization Example | |
Stream Benefits | |
20 | Networking |
Networking Basics | |
The Networking Classes and Interfaces | |
InetAddress | |
Factory Methods | |
Instance Methods | |
Inet4Address and Inet6Address | |
TCP/IP Client Sockets | |
URL | |
URLConnection | |
HttpURLConnection | |
The URI Class | |
Cookies | |
TCP/IP Server Sockets | |
Datagrams | |
DatagramSocket | |
DatagramPacket | |
A Datagram Example | |
21 | The Applet Class |
Two Types of Applets | |
Applet Basics | |
The Applet Class | |
Applet Architecture | |
An Applet Skeleton | |
Applet Initialization and Termination | |
Overriding update( ) | |
Simple Applet Display Methods | |
Requesting Repainting | |
A Simple Banner Applet | |
Using the Status Window | |
The HTML APPLET Tag | |
Passing Parameters to Applets | |
Improving the Banner Applet | |
getDocumentBase( ) and getCodeBase( ) | |
AppletContext and showDocument( ) | |
The AudioClip Interface | |
The AppletStub Interface | |
Outputting to the Console | |
22 | Event Handling |
Two Event Handling Mechanisms | |
The Delegation Event Model | |
Events | |
Event Sources | |
Event Listeners | |
Event Classes | |
The ActionEvent Class | |
The AdjustmentEvent Class | |
The ComponentEvent Class | |
The ContainerEvent Class | |
The FocusEvent Class | |
The InputEvent Class | |
The ItemEvent Class | |
The KeyEvent Class | |
The MouseEvent Class | |
The MouseWheelEvent Class | |
The TextEvent Class | |
The WindowEvent Class | |
Sources of Events | |
Event Listener Interfaces | |
The ActionListener Interface | |
The AdjustmentListener Interface | |
The ComponentListener Interface | |
The ContainerListener Interface | |
The FocusListener Interface | |
The ItemListener Interface | |
The KeyListener Interface | |
The MouseListener Interface | |
The MouseMotionListener Interface | |
The MouseWheelListener Interface | |
The TextListener Interface | |
The WindowFocusListener Interface | |
The WindowListener Interface | |
Using the Delegation Event Model | |
Handling Mouse Events | |
Handling Keyboard Events | |
Adapter Classes | |
Inner Classes | |
Anonymous Inner Classes | |
23 | Introducing the AWT: Working with Windows, Graphics |
AWT Classes | |
Window Fundamentals | |
Component | |
Container | |
Panel | |
Window | |
Frame | |
Canvas | |
Working with Frame Windows | |
Setting the Window’s Dimensions | |
Hiding and Showing a Window | |
Setting a Window’s Title | |
Closing a Frame Window | |
Creating a Frame Window in an Applet | |
Handling Events in a Frame Window | |
Creating a Windowed Program | |
Displaying Information Within a Window | |
Working with Graphics | |
Drawing Lines | |
Drawing Rectangles | |
Drawing Ellipses and Circles | |
Drawing Arcs | |
Drawing Polygons | |
Sizing Graphics | |
Working with Color | |
Color Methods | |
Setting the Current Graphics Color | |
A Color Demonstration Applet | |
Setting the Paint Mode | |
Working with Fonts | |
Determining the Available Fonts | |
Creating and Selecting a Font | |
Obtaining Font Information | |
Managing Text Output Using FontMetrics | |
Displaying Multiple Lines of Text | |
Centering Text | |
Multiline Text Alignment | |
24 | Using AWT Controls, Layout Managers, and Menus |
Control Fundamentals | |
Adding and Removing Controls | |
Responding to Controls | |
The HeadlessException | |
Labels | |
Using Buttons | |
Handling Buttons | |
Applying Check Boxes | |
Handling Check Boxes | |
CheckboxGroup | |
Choice Controls | |
Handling Choice Lists | |
Using Lists | |
Handling Lists | |
Managing Scroll Bars | |
Handling Scroll Bars | |
Using a TextField | |
Handling a TextField | |
Using a TextArea | |
Understanding Layout Managers | |
FlowLayout | |
BorderLayout | |
Using Insets | |
GridLayout | |
CardLayout | |
GridBagLayout | |
Menu Bars and Menus | |
Dialog Boxes | |
FileDialog | |
Handling Events by Extending AWT Components | |
Extending Button | |
Extending Checkbox | |
Extending a Check Box Group | |
Extending Choice | |
Extending List | |
Extending Scrollbar | |
25 | Images |
File Formats | |
Image Fundamentals: Creating, Loading, and Displaying | |
Creating an Image Object | |
Loading an Image | |
Displaying an Image | |
ImageObserver | |
Double Buffering | |
MediaTracker | |
ImageProducer | |
Memory image source | |
ImageConsumer | |
PixelGrabber | |
ImageFilter | |
CropImageFilter | |
RGBImageFilter | |
Cell Animation | |
Additional Imaging Classes | |
26 | The Concurrency Utilities |
The Concurrent API Packages | |
Using Synchronization Objects | |
Semaphore | |
CountDownLatch | |
CyclicBarrier | |
Exchanger | |
Using an Executor | |
A Simple Executor Example | |
Using Callable and Future | |
The TimeUnit Enumeration | |
The Concurrent Collections | |
Locks | |
Atomic Operations | |
The Concurrency Utilities Versus Java’s Traditional Approach | |
27 | NIO, Regular Expressions, and Other Packages |
The Core Java API Packages | |
NIO | |
NIO Fundamentals | |
Charsets and Selectors | |
Using the NIO System | |
Is NIO the Future of I/O Handling? | |
Regular Expression Processing | |
Pattern | |
Matcher | |
Regular Expression Syntax | |
Demonstrating Pattern Matching | |
Two Pattern-Matching Options | |
Exploring Regular Expressions | |
Reflection | |
Remote Method Invocation (RMI) | |
A Simple Client/Server Application Using RMI | |
Text Formatting | |
DateFormat Class | |
SimpleDateFormat Class | |
Part III Software Development Using Java | |
28 | Java Beans |
What Is a Java Bean? | |
Advantages of Java Beans | |
Introspection | |
Design Patterns for Properties | |
Design Patterns for Events | |
Methods and Design Patterns | |
Using the BeanInfo Interface | |
Bound and Constrained Properties | |
Persistence | |
Customizers | |
The Java Beans API | |
Introspector | |
PropertyDescriptor | |
EventSetDescriptor | |
MethodDescriptor | |
A Bean Example | |
29 | Introducing Swing |
The Origins of Swing | |
Swing Is Built on the AWT | |
Two Key Swing Features | |
Swing Components Are Lightweight | |
Swing Supports a Pluggable Look and Feel | |
The MVC Connection | |
Components and Containers | |
Components | |
Containers | |
The Top-Level Container Panes | |
The Swing Packages | |
A Simple Swing Application | |
Event Handling | |
Create a Swing Applet | |
Painting in Swing | |
Painting Fundamentals | |
Compute the Paintable Area | |
A Paint Example | |
30 | Exploring Swing |
JLabel and ImageIcon | |
JTextField | |
The Swing Buttons | |
JButton | |
JToggleButton | |
Check Boxes | |
Radio Buttons | |
JTabbedPane | |
JScrollPane | |
JList | |
JComboBox | |
Trees | |
JTable | |
Continuing Your Exploration of Swing | |
31 | Servlets |
Background | |
The Life Cycle of a Servlet | |
Using Tomcat for Servlet Development | |
A Simple Servlet | |
Create and Compile the Servlet Source Code | |
Start Tomcat | |
Start a Web Browser and Request the Servlet | |
The Servlet API | |
The javax | |
The Servlet Interface | |
The ServletConfig Interface | |
The ServletContext Interface | |
The ServletRequest Interface | |
The ServletResponse Interface | |
The GenericServlet Class | |
The ServletInputStream Class | |
The ServletOutputStream Class | |
The Servlet Exception Classes | |
Reading Servlet Parameters | |
The javax | |
The HttpServletRequest Interface | |
The HttpServletResponse Interface | |
The HttpSession Interface | |
The HttpSessionBindingListener Interface | |
The Cookie Class | |
The HttpServlet Class | |
The HttpSessionEvent Class | |
The HttpSessionBindingEvent Class | |
Handling HTTP Requests and Responses | |
Handling HTTP GET Requests | |
Handling HTTP POST Requests | |
Using Cookies | |
Session Tracking | |
Part IV Applying Java | |
32 | Financial Applets and Servlets |
Finding the Payments for a Loan | |
The RegPay Fields | |
The init( ) Method | |
The makeGUI( ) Method | |
The actionPerformed( ) Method | |
The compute( ) Method | |
Finding the Future Value of an Investment | |
Finding the Initial Investment Required to Achieve a Future Value | |
Finding the Initial Investment Needed for a Desired Annuity | |
Finding the Maximum Annuity for a Given Investment | |
Finding the Remaining Balance on a Loan | |
Creating Financial Servlets | |
Converting the RegPay Applet into a Servlet | |
The RegPayS Servlet | |
Some Things to Try | |
33 | Creating a Download Manager in Java |
Understanding Internet Downloads | |
An Overview of the Download Manager | |
The Download Class | |
The Download Variables | |
The Download Constructor | |
The download( ) Method | |
The run( ) Method | |
The stateChanged( ) Method | |
Action and Accessor Methods | |
The ProgressRenderer Class | |
The DownloadsTableModel Class | |
The addDownload( ) Method | |
The clearDownload( ) Method | |
The getColumnClass( ) Method | |
The getValueAt( ) Method | |
The update( ) Method | |
The DownloadManager Class | |
The DownloadManager Variables | |
The DownloadManager Constructor | |
The verifyUrl( ) Method | |
The tableSelectionChanged( ) Method | |
The updateButtons( ) Method | |
Handling Action Events | |
Compiling and Running the Download Manager | |
Enhancing the Download Manager |
thank you so much sir….
Was this answer helpful?
LikeDislikeThanks Priya. I will be updating other content, Programs and text/video tutorials very soon
Was this answer helpful?
LikeDislikeThank u sir..itz really helpful..
Was this answer helpful?
LikeDislikeThank You sir..
Was this answer helpful?
LikeDislikeThis is really helpful…thank you sir
Was this answer helpful?
LikeDislikeThis solution has been deemed correct by the post author
Thank you all. Let me know in case you want any specific tutorial related to your exam.
Was this answer helpful?
LikeDislike