Save This Page
Home » jdo2-tck-2.3-ea-src » org.apache.jdo.tck.pc.companyAnnotatedJPA » [javadoc | source]
org.apache.jdo.tck.pc.companyAnnotatedJPA
public class: JPAAppDepartment [javadoc | source]
java.lang.Object
   org.apache.jdo.tck.pc.companyAnnotatedJPA.JPAAppDepartment

All Implemented Interfaces:
    DeepEquality, Comparator, Serializable, IDepartment, Comparable

This class represents a department within a company.
Nested Class Summary:
public static class  JPAAppDepartment.Oid  The application identity class associated with the Department class. 
Field Summary
public static final  int RECOMMENDED_NO_OF_EMPS     
Constructor:
 public JPAAppDepartment() 
 public JPAAppDepartment(long deptid,
    String name) 
    Construct a Department instance.
    Parameters:
    deptid - The department id.
    name - The name of the department.
 public JPAAppDepartment(long deptid,
    String name,
    ICompany company) 
    Construct a Department instance.
    Parameters:
    deptid - The department id.
    name - The name of the department.
    company - The company that the department is associated with.
 public JPAAppDepartment(long deptid,
    String name,
    ICompany company,
    IEmployee employeeOfTheMonth) 
    Construct a Department instance.
    Parameters:
    deptid - The department id.
    name - The name of the department.
    company - The company that the department is associated with.
    employeeOfTheMonth - The employee of the month the department is associated with.
Method from org.apache.jdo.tck.pc.companyAnnotatedJPA.JPAAppDepartment Summary:
addEmployee,   addFundedEmp,   compare,   compare,   compareTo,   compareTo,   deepCompareFields,   equals,   getCompany,   getDeptid,   getEmployeeOfTheMonth,   getEmployees,   getFieldRepr,   getFundedEmps,   getName,   hashCode,   removeEmployee,   removeFundedEmp,   setCompany,   setDeptid,   setEmployeeOfTheMonth,   setEmployees,   setFundedEmps,   setName,   toString
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.apache.jdo.tck.pc.companyAnnotatedJPA.JPAAppDepartment Detail:
 public  void addEmployee(JPAAppEmployee emp) 
    Add an employee to the department.
 public  void addFundedEmp(JPAAppEmployee emp) 
    Add an employee to the collection of funded employees of this department.
 public int compare(Object o1,
    Object o2) 
    Compare two instances. This is a method in Comparator.
 public static int compare(JPAAppDepartment o1,
    JPAAppDepartment o2) 
    Compares its two IDepartment arguments for order. Returns a negative integer, zero, or a positive integer as the first argument is less than, equal to, or greater than the second.
 public int compareTo(Object o) 
    Compares this object with the specified object for order. Returns a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object.
 public int compareTo(JPAAppDepartment other) 
    Compares this object with the specified Department object for order. Returns a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object.
 public boolean deepCompareFields(Object other,
    EqualityHelper helper) 
    Returns true if all the fields of this instance are deep equal to the coresponding fields of the other JPAAppDepartment.
 public boolean equals(Object obj) 
    Indicates whether some other object is "equal to" this one.
 public ICompany getCompany() 
    Get the company associated with the department.
 public long getDeptid() 
    Get the department id.
 public IEmployee getEmployeeOfTheMonth() 
    Get the employee of the month associated with the department.
 public Set getEmployees() 
    Get the employees in the department as an unmodifiable set.
 protected String getFieldRepr() 
    Returns a String representation of the non-relationship fields.
 public Set getFundedEmps() 
    Get the funded employees in the department as an unmodifiable set.
 public String getName() 
    Get the name of the department.
 public int hashCode() 
    Returns a hash code value for the object.
 public  void removeEmployee(JPAAppEmployee emp) 
    Remove an employee from the department.
 public  void removeFundedEmp(JPAAppEmployee emp) 
    Remove an employee from collection of funded employees of this department.
 public  void setCompany(ICompany company) 
    Set the company for the department.
 public  void setDeptid(long id) 
    Set the id associated with this object.
 public  void setEmployeeOfTheMonth(IEmployee employeeOfTheMonth) 
    Set the employee of the month for the department.
 public  void setEmployees(Set employees) 
    Set the employees to be in this department.
 public  void setFundedEmps(Set employees) 
    Set the funded employees to be in this department.
 public  void setName(String name) 
    Set the name of the department.
 public String toString() 
    Returns a String representation of a JPAAppDepartment object.