这是闻名的 Chidamber and Kemerer公理之一。以下面代码来说明: public class RegistrationManager {
public void createRegistration(RegistrationData regData){
DataaccessManager manager = new DataAccessManager(); AuditManager auditManager = new AuditManager(); //save the registration manager.saveRegistration(regData); //audit the creattion auditManager.createAuditRecord(regData);
}
public Registration findRegistration(String regNumber){
DataAccessManager manager = new DataAccessManager(); Registration reg = null;
//find the registration reg = manager.findRegsitration(regNumber);