Class CommunityMember

java.lang.Object
  extended by CommunityMember

public class CommunityMember
extends java.lang.Object

CommunityMember class definition maintains and returns first name and last name information.

Version:
Copyright (c) 2003
Author:
Carl B. Struck

Constructor Summary
CommunityMember(java.lang.String firstName, java.lang.String lastName)
          The constructor sets initial values for the firstName and lastName fields.
 
Method Summary
 java.lang.String getFirstName()
          Returns current value of the firstName field.
 java.lang.String getLastName()
          Returns current value of the lastName field.
static java.lang.String printHeading()
          Static method that returns heading lines to be printed at beginning of a columnar report.
 java.lang.String printLine()
          Returns detail line information for firstName and lastName fields for a columnar report.
 void setCommunityMember(java.lang.String firstName, java.lang.String lastName)
          Sets values for the firstName and lastName fields by calling setFirstName and setLastName methods.
 void setFirstName(java.lang.String firstName)
          Sets the value for the firstName field converted to all uppercase letters.
 void setLastName(java.lang.String lastName)
          Sets the value for the lastName field converted to all uppercase letters.
 java.lang.String toString()
          Returns formatted firstName and lastName fields including text labels.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CommunityMember

public CommunityMember(java.lang.String firstName,
                       java.lang.String lastName)
The constructor sets initial values for the firstName and lastName fields.

Parameters:
firstName - Member's first name.
lastName - Member's last name.
Method Detail

getFirstName

public java.lang.String getFirstName()
Returns current value of the firstName field.

Returns:
First name of member as type String.

getLastName

public java.lang.String getLastName()
Returns current value of the lastName field.

Returns:
Last name of member as type String.

printHeading

public static java.lang.String printHeading()
Static method that returns heading lines to be printed at beginning of a columnar report. Includes columns for Employee, Faculty, Administrator and Teacher classes.

Returns:
Heading lines as type String.

printLine

public java.lang.String printLine()
Returns detail line information for firstName and lastName fields for a columnar report.

Returns:
First name and last name as part of a detail line as type String.

setCommunityMember

public void setCommunityMember(java.lang.String firstName,
                               java.lang.String lastName)
Sets values for the firstName and lastName fields by calling setFirstName and setLastName methods.

Parameters:
firstName - Member's first name.
lastName - Member's last name.

setFirstName

public void setFirstName(java.lang.String firstName)
Sets the value for the firstName field converted to all uppercase letters. An empty String value indicates that the first name field is empty.

Parameters:
firstName - Member's first name.

setLastName

public void setLastName(java.lang.String lastName)
Sets the value for the lastName field converted to all uppercase letters. An empty String value indicates that the last name field is empty.

Parameters:
lastName - Member's first name.

toString

public java.lang.String toString()
Returns formatted firstName and lastName fields including text labels.

Overrides:
toString in class java.lang.Object
Returns:
Formatted first name and last name fields as type String.