midterms Flashcards
is a method that has only the heading with no body
abstract method
a class that is declared with the reserved word abstract in its heading.
abstract class
they “wrap” the primitive data type into an object of that class.
Wrapper class
an abnormal condition that occurs at runtime.
Exception
block of code that always executes, regardless of whether or not an exception is thrown.
finally block
handles the exception
catch block
a section of a code that executes when an Exception is passed to it.
catch block
Constructs a new String with the value “” containing no characters. The value is not null.
public String()
Constructs a new String that contains the same sequence of characters as the specified String argument.
public String (String value)
Constructs a new String containing the same sequence of characters contained in the
character array argument.
public String (char[] value)
Compares the current String object to str, and returns 0 only if the two strings contain the same sequence of characters (case sensative)
public int compareTo (String str)
Compares the current String object with obj and returns true if obj is another String
containing the same sequence of characters; false is returned otherwise.
public boolean equals (Object obj)
Performs a case-insensitive comparison of the current String object with str and returns true if str is another String containing the same sequence (ignoring case) of characters; false is returned otherwise.
public boolean equalsIgnoreCase (String str)
Returns the character at the specified index. The index may range from 0 to length() - 1.
public char charAt( int index )
Concatenates the specified String to the end of the current (this) String. If the length of the argument string is 0, then this String is returned.
public String concat( String str )