java.awt.Cursor (JDK 1.1)
This class represents a mouse cursor. It defines a number of constants, each of which specify one of the supported cursor images. Pass one of these constants to the constructor to create a cursor of the specified type, and call getType() to determine the type of an existing Cursor object.
Since there are only a fixed number of available cursors, the static method getPredefinedCursor() is more efficient than the Cursor() constructor--it maintains a cache of Cursor objects that can be reused. The static getDefaultCursor() method returns the system default cursor.
public classCursorextends Object implements Serializable { //Public ConstructorpublicCursor(inttype); //Cursor Constantspublic static final intDEFAULT_CURSOR; public static final intCROSSHAIR_CURSOR,HAND_CURSOR,MOVE_CURSOR; public static final intTEXT_CURSOR,WAIT_CURSOR; public static final intN_RESIZE_CURSOR,S_RESIZE_CURSOR; public static final intE_RESIZE_CURSOR,W_RESIZE_CURSOR; public static final intNE_RESIZE_CURSOR,NW_RESIZE_CURSOR; public static final intSE_RESIZE_CURSOR,SW_RESIZE_CURSOR; //Class Variablesprotected static Cursor[]predefined; //Class Methodspublic static CursorgetDefaultCursor(); public static CursorgetPredefinedCursor(inttype); //Public Instance Methodspublic intgetType(); }
Passed To:
Component.setCursor(), ComponentPeer.setCursor()
Returned By:
Component.getCursor(), Cursor.getDefaultCursor(), Cursor.getPredefinedCursor()
Type Of:
Cursor.predefined