Package edu.nwmissouri.animalList
Class Giraffe
java.lang.Object
edu.nwmissouri.animalList.Animal
edu.nwmissouri.animalList.Giraffe
Giraffe class (derived subclass of the superclass Animal)
- Author:
- Himaja Reddy Maddi
-
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondouble
getGiraffeMultiplication
(double leg1, int leg2) Custom Giraffe functionvoid
move()
abstract move() - has no implementationvoid
multiply()
Custom Giraffe function for performing an operationvoid
speak()
abstract speak() - has no implementation
-
Constructor Details
-
Giraffe
Giraffe constructor- Parameters:
name
- - the name of this Giraffe
-
-
Method Details
-
speak
public void speak()Description copied from class:Animal
abstract speak() - has no implementation -
move
public void move()Description copied from class:Animal
abstract move() - has no implementation -
multiply
public void multiply()Custom Giraffe function for performing an operation -
getGiraffeMultiplication
public double getGiraffeMultiplication(double leg1, int leg2) Custom Giraffe function- Parameters:
leg1
- double inputleg2
- int input- Returns:
- double sum
-