Crossfire JXClient, Trunk
Inheritance Class Reference
+ Collaboration diagram for Inheritance:

Classes

interface  Diveable
 
class  Duck
 
class  Fish
 
interface  Swimable
 
class  Tuna
 

Static Public Member Functions

static void main (final String[] args)
 

Detailed Description

The sample illustrates rules to resolve conflicts between inheritance candidates with default methods. There are two simple rules:

  • Class wins. If the superclass has a concrete or abstract declaration of this method, then it is preferred over all defaults.
  • Subtype wins. If an interface extends another interface, and both provide a default, then the more specific interface wins.

Definition at line 42 of file Inheritance.java.

Member Function Documentation

◆ main()

static void Inheritance.main ( final String[]  args)
static

Illustrate behavior of the classes: Tuna and Duck

Parameters
argscommand line arguments

Definition at line 133 of file Inheritance.java.


The documentation for this class was generated from the following file: