|
public class ClassName
implementsInterfaceName, InterfaceName,
...
{
methods
instance variables
}
|
Example:
|
public class BankAccount
implements Measurable
{
// other BankAccount methods
public double getMeasure()
{
// method implementation
}
}
|
Purpose:
To define a new class that implements the methods of an
interface |