Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
  /*
   * 
   */
  package net.officefloor.model.office;
  
  
 
 @Generated("net.officefloor.model.generate.ModelGenerator")
 public class AdministratorToOfficeTeamModel extends AbstractModel implements ConnectionModel {
 
     public static enum AdministratorToOfficeTeamEvent {
      CHANGE_OFFICE_TEAM_NAME, CHANGE_ADMINISTRATOR, CHANGE_OFFICE_TEAM
     }

    
Default constructor.
 
     public AdministratorToOfficeTeamModel() {
     }

    
Convenience constructor for new non-linked instance.
 
       String officeTeamName
     ) {
         this. = officeTeamName;
     }

    
Convenience constructor.
 
       String officeTeamName
     , AdministratorModel administrator
     , OfficeTeamModel officeTeam
     ) {
         this. = officeTeamName;
         this. = administrator;
         this. = officeTeam;
     }

    
Convenience constructor allowing XY initialising.
 
       String officeTeamName
     , AdministratorModel administrator
     , OfficeTeamModel officeTeam
     , int x
     , int y
     ) {
         this. = officeTeamName;
         this. = administrator;
         this. = officeTeam;
         this.setX(x);
         this.setY(y);
     }

    
Office team name.
 
     private String officeTeamName;
 
     public String getOfficeTeamName() {
         return this.;
     }
 
     public void setOfficeTeamName(String officeTeamName) {
         String oldValue = this.;
         this. = officeTeamName;
     }

    
Administrator.
 
     private AdministratorModel administrator;
 
     public AdministratorModel getAdministrator() {
         return this.;
     }
 
     public void setAdministrator(AdministratorModel administrator) {
         AdministratorModel oldValue = this.;
         this. = administrator;
     }

    
Office team.
 
     private OfficeTeamModel officeTeam;
 
     public OfficeTeamModel getOfficeTeam() {
         return this.;
    }
    public void setOfficeTeam(OfficeTeamModel officeTeam) {
        OfficeTeamModel oldValue = this.;
        this. = officeTeam;
    }
    /*
     * ConnectionModel
     */
    public boolean isRemovable() {
        return true;
    }
    public void connect() {
        this..setOfficeTeam(this);
        this..addAdministrator(this);
    }
    public void remove() {
        this..setOfficeTeam(null);
        this..removeAdministrator(this);
    }
New to GrepCode? Check out our FAQ X