Class Acrobat

java.lang.Object
  |
  +--Acrobat

public class Acrobat
extends java.lang.Object

This class can be used to represent a member of the CSE 142 Acrobat community. In this simple implementation, such people have a name and a cumulative action count and they know how to twirl, clap, and count.


Constructor Summary
Acrobat(java.lang.String given, java.lang.String family)
          Create a new Acrobat using the name information provided.
 
Method Summary
 void clap(int k)
          Clap as instructed.
 int getActionCount()
          Tell the caller how many things we've done so far.
 java.lang.String getFamilyName()
          Tell the caller what our family name is.
 java.lang.String getGivenName()
          Tell the caller what our given name is.
 void twirl(int k)
          Twirl around as instructed.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Acrobat

public Acrobat(java.lang.String given,
               java.lang.String family)
Create a new Acrobat using the name information provided.

Parameters:
given - the specific name of this person
family - the surname or family name of this person
Method Detail

twirl

public void twirl(int k)
Twirl around as instructed. Note that since we don't yet have any fancy graphics capabilities our twirling is limited to just saying that we twirled, without any actual twirlosity.

Parameters:
k - the number of times to twirl

clap

public void clap(int k)
Clap as instructed. No fancy audio capabilities, so our clapping is limited to just saying that we clapped.

Parameters:
k - the number of times to clap

getActionCount

public int getActionCount()
Tell the caller how many things we've done so far. Note that this method returns the information to the method that called us, it does not write anything to the screen for the user to read.

Returns:
the number of claps and twirls to date

getGivenName

public java.lang.String getGivenName()
Tell the caller what our given name is.

Returns:
the given name

getFamilyName

public java.lang.String getFamilyName()
Tell the caller what our family name is.

Returns:
the family name