/*                                      
 * Actor.java 
 *
 * Version: 
 *     $Id: Actor.java,v 1.1 2002/03/17 12:06:14 jmg Exp $ 
 * 
 * Revisions: 
 *     $Log: Actor.java,v $
 *     Revision 1.1  2002/03/17 12:06:14  jmg
 *     Initial revision
 * 
 */

/**
 * Simple Actor class.  Represents an actor that needs to get 
 * paid
 *
 * @author Joe Geigel
 */
public class Actor {

    /**
     * The basic rate per perfomance.  Common for all actors
     */
    private static final double PAYRATE = 200.0;

    /**
     * The name of the actor
     */
    private String myName;

    /**
     * The number of perfomances worked
     */
    private int nPerformances;

     /**
      *
      * Constructor for actor class
      *
      * @param name The actor's name
      */
    public Actor (String name){
	myName = name;
	nPerformances = 0;
    }

    /**
     * Calculates and returns the weekly pay for the actor
     *
     * @returns The weekly pay
     */
    public double calculatePay ()
    {
	return PAYRATE * nPerformances;
    }


    /**
     * Sets the number of performances for the week
     *
     * @param n number of performances played during the week
     */
    public void perform (int n)
    {
	nPerformances = n;
    }

    
}
