//*******************************************************************
//
//   Soap_Box.java          In Text          Application
//
//   Authors:  Lewis and Loftus
//
//   Classes:  Soap_Box
//             Kant
//
//   Interfaces:  Philosopher
//
//*******************************************************************


//-------------------------------------------------------------------
//
//  Class Soap_Box demonstrates a class that implements an
//  interface.
//
//  Methods:
//
//     public static void main (String[] args)
//
//-------------------------------------------------------------------

public class Soap_Box {

   //===========================================================
   //  Creates a Kant object and invokes the method that it
   //  had to define because Kant implements the Philosopher
   //  interface.
   //===========================================================
   public static void main (String[] args) {

      Kant immanual = new Kant();

      System.out.println (immanual.pontificate());

   } // method main

} // class Soap_Box

//-------------------------------------------------------------------
//
//  Interface Philosopher lists the methods that must be defined
//  by any class that implements the interface.
//
//  Methods:
//
//     String pontificate()
//
//-------------------------------------------------------------------

interface Philosopher {

   //===========================================================
   //  Should be defined to return a statement made by a
   //  particular philosopher
   //===========================================================
   String pontificate();

} // class Philosopher

//-------------------------------------------------------------------
//
//  Class Kant represents the teachings of philosopher Immanual
//  Kant.  It implements the Philosopher interface, and therefore
//  must define method pontificate.
//
//  Methods:
//
//     public String pontificate()
//
//-------------------------------------------------------------------

class Kant implements Philosopher {

   //===========================================================
   //  Returns a key philosophical statement by Kant.
   //===========================================================
   public String pontificate() {

      return "Follow the Categorical Imperitive!";

   } // method pontificate

} // class Kant


