Class RoaringLion

java.lang.Object
edu.nwmissouri.animalList.Animal
edu.nwmissouri.animalList.RoaringLion

public class RoaringLion extends Animal
This class is a custom Lion class, which is defining the lion behavior
Author:
Anil Kumar Kolla(S545232@nwmissouri.edu)
  • Field Summary

    Fields inherited from class edu.nwmissouri.animalList.Animal

    gender, name
  • Constructor Summary

    Constructors
    Constructor
    Description
    this constructor passing the animal name to parent class
  • Method Summary

    Modifier and Type
    Method
    Description
    double
    getLionAddition(double input1, int input2)
    this function returns the sum the two input parameters
    void
    this function is to declare the local variables for to call an actual addition function
    void
    this function prints the animal movement
    void
    this function prints the animal sound

    Methods inherited from class edu.nwmissouri.animalList.Animal

    getGender, getName, setGender

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • RoaringLion

      public RoaringLion(String name)
      this constructor passing the animal name to parent class
      Parameters:
      name -
  • Method Details

    • speak

      public void speak()
      this function prints the animal sound
      Specified by:
      speak in class Animal
    • move

      public void move()
      this function prints the animal movement
      Specified by:
      move in class Animal
    • lionAddtion

      public void lionAddtion()
      this function is to declare the local variables for to call an actual addition function
    • getLionAddition

      public double getLionAddition(double input1, int input2)
      this function returns the sum the two input parameters