Fields Summary |
---|
public static final oreilly.hcj.datamodeling.constraints.NumericConstraint | CUSTOMER_ID_CONSTRAINTConstraint for the property customerID. |
public static final oreilly.hcj.datamodeling.constraints.StringConstraint | FIRST_NAME_CONSTRAINTConstraint for the property firstName. |
public static final oreilly.hcj.datamodeling.constraints.StringConstraint | LAST_NAME_CONSTRAINTConstraint for the property lastName. |
public static final oreilly.hcj.datamodeling.constraints.StringConstraint | PHONE_CONSTRAINTConstraint for the property phone. |
public static final oreilly.hcj.datamodeling.constraints.CollectionConstraint | PURCHASES_CONSTRAINTConstraint for the property purchases. |
Integer | customerIDHolds the value of the property customerID. |
List | purchasesHolds the value of the property purchases. |
String | firstNameHolds the value of the property firstName. |
String | lastNameHolds the value of the property lastName. |
String | phoneHolds the value of the property phone. |
Methods Summary |
---|
public boolean | equals(java.lang.Object obj)
if (!(obj instanceof Customer)) {
return false;
} else {
return (((Customer)obj).getCustomerID().equals(this.customerID));
}
|
public java.lang.Integer | getCustomerID()Gets the value of the property customerID.
return this.customerID;
|
public java.lang.String | getFirstName()Gets the value of the property firstName.
return this.firstName;
|
public java.lang.String | getLastName()Gets the value of the property lastName.
return this.lastName;
|
public java.lang.String | getPhone()Gets the value of the property phone.
return this.phone;
|
public java.util.List | getPurchases()Gets the value of the property purchases.
return Collections.unmodifiableList(this.purchases);
|
public int | hashCode()
return this.customerID.hashCode();
|
public void | setCustomerID(java.lang.Integer customerID)Sets the value of the property customerID.
CUSTOMER_ID_CONSTRAINT.validate(customerID);
final Integer oldCustomerID = this.customerID;
this.customerID = customerID;
propertyChangeSupport.firePropertyChange("customerID", oldCustomerID,
this.customerID);
|
public void | setFirstName(java.lang.String firstName)Sets the value of the property firstName.
FIRST_NAME_CONSTRAINT.validate(firstName);
final String oldFirstName = this.firstName;
this.firstName = firstName;
propertyChangeSupport.firePropertyChange("firstName", oldFirstName, this.firstName);
|
public void | setLastName(java.lang.String lastName)Sets the value of the property lastName.
LAST_NAME_CONSTRAINT.validate(lastName);
final String oldLastName = this.lastName;
this.lastName = lastName;
propertyChangeSupport.firePropertyChange("lastName", oldLastName, this.lastName);
|
public void | setPhone(java.lang.String phone)Sets the value of the property phone.
PHONE_CONSTRAINT.validate(phone);
final String oldPhone = this.phone;
this.phone = phone;
propertyChangeSupport.firePropertyChange("phone", oldPhone, this.phone);
|
public void | setPurchases(java.util.List purchases)Sets the value of the property purchases.
PURCHASES_CONSTRAINT.validate(purchases);
final List oldPurchases = getPurchases();
this.purchases = new ArrayList(purchases);
propertyChangeSupport.firePropertyChange("purchases", oldPurchases, this.purchases);
|