Skip to content

Instantly share code, notes, and snippets.

@RajaniCode
Last active May 29, 2024 10:06
Show Gist options
  • Select an option

  • Save RajaniCode/daa08edf753d4e7b3aa98945f451febc to your computer and use it in GitHub Desktop.

Select an option

Save RajaniCode/daa08edf753d4e7b3aa98945f451febc to your computer and use it in GitHub Desktop.
Java 6 To 1
// Java 6
/*
Java SE 6 adds no major features to the Java language proper, but it does enhance the API libraries, add several new packages, and offer improvements to the run time.
*/
/*
# Float and Double Constants MAX_EXPONENT
MIN_EXPONENT
MIN_NORMAL
# System Class
static Console console ( ) method
# Math Class
static double scalb(double arg, int factorr) method
static float scalb(float arg, int factor) method
static double nextAfter(double arg, double toward) method
static float nextAfter(float arg, double toward) method
static double nextUp(double arg)
static float nextUp(float arg) method
static double copySign(double arg, double signarg) method
static float copySign(float arg, float signarg) method
static int getExponent(double arg) method
static int getExponent(float arg) method
# java.uti
ArrayDeque
ServiceLoader
Deque
NavigableMap
NavigableSet
# Collection
static <E> Set<E> newSetFromMap(Map<E, Boolean> m) method
# Arrays
binarySearch( ) method
copyOf( ) method
copyOfRange( ) method
# Methods Defined by Properties (subclass of Hashtable)
void load(Reader streamIn) throws IOException method
void store(Writer streamOut, String description) throws IOException method
Set<String> stringPropertyNames( ) method
# Methods Defined by ResourceBundle
static final void clearCache( ) method
static final void clearCache(ClassLoader ldr) method
boolean containsKey(String k) method
static final ResourceBundle getBundle(String familyName, ResourceBundle.Control cntl) method
static final ResourceBundle getBundle(String familyName, Locale loc, ResourceBundle.Control cntl) method
static ResourceBundle getBundle(String familyName, Locale loc, ClassLoader ldr, ResourceBundle.Control cntl) method
protected Set<String> handleKeySet( ) method
Set<String> keySet( ) method
# Utility Class
ServiceLoader
# java.util.spi package, which supports service providers for text formatting classes injava.text and utility classes injava.util.
# Java I/O Class
Console
# File Methods
long getFreeSpace( ) method
long getTotalSpace( ) method
long getUsableSpace( ) method
# Console Class
# IOError Exception
# Networking Classes
ContentHandler
CookieManager
HttpCookie
IDN
CookiePolicy
CookieStore
# MouseEvent Class
NOBUTTON value
# GridBagLayout
GridBagConstraints.BASELINE GridBagConstraints.BASELINE_TRAILING GridBagConstraints.BASELINE_LEADING GridBagConstraints.ABOVE_BASELINE GridBagConstraints.ABOVE_BASELINE_LEADING GridBagConstraints.ABOVE_BASELINE_TRAILING GridBagConstraints.BELOW_BASELINE GridBagConstraints. BELOW_BASELINE_TRAILING GridBagConstraints.BELOW_BASELINE_LEADING
# TimeUnit Enumeration
DAYS
HOURS
MINUTES
long toDays(long tval) method
long toHours(long tval) method
long toMinutes(long tval) method
# Concurrent Collections
ConcurrentSkipListMap
ConcurrentSkipListSet
LinkedBlockingDeque
# Buffers
abstract boolean hasArray( ) method
abstract isDirect( ) method
# Program rmiregistry, which executes on the server machine.
# Look-and-feels, such as metal and Motif, that are available to all Swing users.
# Swing Packages
javax.swing javax.swing.event javax.swing.border javax.swing.filechooser javax.swing.colorchooser javax.swing.plaf javax.swing.plaf.basic javax.swing.plaf.synth javax.swing.text.html javax.swing.tree javax.swing.plaf.metal javax.swing.table javax.swing.text.html.parser javax.swing.undo
*/
// Java 5
/*
1. Generics
2. Annotations
3. Autoboxing and Unboxing
4. Typesafe Enumerations
5. Enhanced for-each Style for Loop
6. Variable-length Arguments (varargs)
7. Static import
8. Formatted I/O
9. Concurrency Utilities
10. Covariant Returns
*/
// Java 2, version 1.4
/*
1. assert keyword
2. channel-based I/O subsystem
3. chained exceptions
4. networking enhancements
*/
/*
# Keyword to Java: assert
# New feature to the exception subsystem: chained exceptions.
# Two constructors and two methods to Throwable
Throwable(Throwable causeExc)
Throwable(String msg, Throwable causeExc)
Throwable getCause( )
Throwable initCause(Throwable causeExc)
# Method Defined byThrowable
Throwable getCause( )
# String and StringBuffer implement the CharSequence interface.
# New way to handle I/O operations, called the new I/O APIs (Additional I/O capabilities which are contained in the java.nio package.)
# Channels
getChannel( ) to the I/O classes
FileInputStream
Socket
FileOutputStream
ServerSocket
RandomAccessFile
DatagramSocket
# java.util.logging package, which supports logging of information related to a program’s execution.
# java.util.prefs package, which encapsulates information relating to user preferences.
# java.util.regex package, which supports regular expression processing.
# Pattern
CharSequence is an interface that defines a read-only set of characters.
# Method Defined by Float
static int compare(floatnum1, floatnum2)
# Method Defined by Double
static int compare(double num1, double num2)
# Character Method
static boolean isMirrored(char ch)
getDirectionality( ), which can be used to determine the direction of a character.
# Methods Defined by Boolean
static String toString(booleanboolVal)
static Boolean valueOf(booleanboolVal)
# Properties
java.class.path
java.class.version
java.compiler
java.ext.dirs
java.home
java.io.tmpdir
java.library.path
java.specification.name java.specification.vendor java.specification.version
java.vendor
java.vendor.url
java.version
java.vm.name
java.vm.specification.name java.vm.specification.vendor java.vm.specification.version java.vm.vendor
java.vm.version
line.separator
os.arch
os.name
os.version
path.separator
user.dir
user.home
user.name
# StackTraceElement class that describes a single stackframe, which is an individual element of a stack trace when an exception occurs.
# Collections enhancements
LinkedHashSet class
RandomAccess interface
LinkedHashMap class
IdentityHashMap class
# BitSet implements the Cloneable interface and defines the methods
int cardinality( )
void clear( )
void clear(int startIndex, int endIndex)
void flip(int index)
void flip(int startIndex, int endIndex)
BitSet get(int startIndex, int endIndex)
boolean intersects(BitSet bitSet)
boolean isEmpty( )
int nextClearBit(int startIndex)
int nextSetBit(int startIndex)
void set(int index, boolean v)
void set(int startIndex, int endIndex)
void set(int startIndex, int endIndex, boolean v)
# SimpleTimeZone(int timeDelta, String tzId, int dstMonth0, int dstDayInMonth0, int dstDay0, int time0, int time0mode, int dstMonth1, int dstDayInMonth1, int dstDay1, int time1, int time1mode, int dstDelta) constructor.
# Valid mode values
STANDARD_TIME
WALL_TIME
UTC_TIME
# Locale(String language) constructor and the mode values.
# Currency class.
# Additional I/O capabilities are contained in the java.nio package.
# File(URI uriObj) constructor.
# getChannel( ) method to FileInputStream.
# FileOutputStream(File fileObj, boolean append) constructor.
# getChannel( ) method to FileOutputStream.
# getChannel( ) method to RandomAccessFile.
# FileWriter(File fileObj, boolean append) constructor.
# Networking classes contained in the java.net package
Inet4Address
Inet6Address
InetSocketAddress
NetworkInterface
URI
# Factory method getByAddress( ), which takes an IP address and returns an InetAddress object.
# getChannel( ) method to Socket.
# getChannel( ) method to ServerSocket.
# MouseWheelEvent.
# ActionEvent Class
ActionEvent(Object src, int type, String cmd, long when, int modifiers) constructor. getWhen( ) method that returns the time at which the event took place.
# Timestamps were added by ActionEvent to help support the improved input focus subsystem.
# FocusEvent Class
Focus Event(Component src, int type, boolean temporaryFlag, Component other)
constructor.
Component getOppositeComponent( ) method.
# InputEvent Class
extended modifier values: ALT_DOWN_MASK ALT_GRAPH_DOWN_MASK BUTTON1_DOWN_MASK BUTTON2_DOWN_MASK BUTTON3_DOWN_MASK META_DOWN_MASK
SHIFT_DOWN_MASK
CTRL_DOWN_MASK
int getModifiersEx( ) method.
# MouseEvent Class
MouseEvent ( Component source, int id, long when, int modifiers, int x, int y, int clickCount, boolean popupTrigger, int button) constructor.
getButton( ) method.
# MouseWheelEvent Class
MouseWheelEvent class encapsulates a mouse wheel even and is a subclass of MouseEvent.
# WindowEvent Class
constant WINDOW_STATE_CHANGED
WindowEvent(Window src, int type, Window other) constructor
WindowEvent(Window src, int type, int fromState, int toState) constructor WindowEvent(Window src, int type, Window other, int fromState, int toState) constructor
Window getOppositeWindow() method
int getOldState() method
int getNewState() method
# Event Listener Interface
MouseWheelListener
WindowFocusListener
# Imaging package called javax.imageio.
# javadoc Tags
{@linkplain
{@value}
# Classes Defined in java.beans
DefaultPersistenceDelegate
Encoder
EventHandler
Expression
PersistenceDelegate
PropertyChangeListenerProxy
Statement
VetoableChangeListenerProxy
XMLDecoder
XMLEncoder
# Abstract Methods Defined by the AppletContext Interface
InputStream getStream(Stringkey)
Iterator getStreamKeys()
void setStream(Stringkey, InputStreamstrm)
*/
// Java 2, version 1.3
/*
# Java Naming and Directory Interface (JNDI) packages
javax.naming
javax.naming.directory
javax.naming.event
javax.naming.ldap
javax.naming.spi
# Java Platform Debugger Architecture (JPDA)
# Java Sound API
# Proxy class and InvocationHandler interface to the java.lang.reflect package.
*/
// Java 2, version 1.2
/*
# strictfp keyword
# Collections
# HotSpot JVM
# Swing
*/
// Java 2, version 1.1
/*
# Inner Classes
# JavaBeans
# JDBC
# Remote Method Invocation (RMI)
# Serialization
# Reflection
# Internationalization
# JIT (Just In Time) Compiler
*/
/*
Courtesies:
https://docs.oracle.com
Java The Complete Reference by Herbert Schildt
*/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment