package org.gmod.gbol.simpleObject.generated;


import org.gmod.gbol.simpleObject.*; 

import java.util.HashSet;
import java.util.Set;

/**
 * Study generated by hbm2java
 */
public abstract class AbstractStudy extends AbstractSimpleObject implements java.io.Serializable {


     private Integer studyId;
     private Publication publication;
     private DBXref dbxref;
     private Contact contact;
     private String name;
     private String description;
     private Set<StudyProperty> studyProperties = new HashSet<StudyProperty>(0);
     private Set<StudyAssay> studyAssays = new HashSet<StudyAssay>(0);
     private Set<StudyDesign> studyDesigns = new HashSet<StudyDesign>(0);

    public AbstractStudy() {
    }

	
    public AbstractStudy(Contact contact, String name) {
        this.contact = contact;
        this.name = name;
    }
    public AbstractStudy(Publication publication, DBXref dbxref, Contact contact, String name, String description, Set<StudyProperty> studyProperties, Set<StudyAssay> studyAssays, Set<StudyDesign> studyDesigns) {
       this.publication = publication;
       this.dbxref = dbxref;
       this.contact = contact;
       this.name = name;
       this.description = description;
       this.studyProperties = studyProperties;
       this.studyAssays = studyAssays;
       this.studyDesigns = studyDesigns;
    }
   
    public Integer getStudyId() {
        return this.studyId;
    }
    
    public void setStudyId(Integer studyId) {
        this.studyId = studyId;
    }
    public Publication getPublication() {
        return this.publication;
    }
    
    public void setPublication(Publication publication) {
        this.publication = publication;
    }
    public DBXref getDbxref() {
        return this.dbxref;
    }
    
    public void setDbxref(DBXref dbxref) {
        this.dbxref = dbxref;
    }
    public Contact getContact() {
        return this.contact;
    }
    
    public void setContact(Contact contact) {
        this.contact = contact;
    }
    public String getName() {
        return this.name;
    }
    
    public void setName(String name) {
        this.name = name;
    }
    public String getDescription() {
        return this.description;
    }
    
    public void setDescription(String description) {
        this.description = description;
    }
    public Set<StudyProperty> getStudyProperties() {
        return this.studyProperties;
    }
    
    public void setStudyProperties(Set<StudyProperty> studyProperties) {
        this.studyProperties = studyProperties;
    }
    public Set<StudyAssay> getStudyAssays() {
        return this.studyAssays;
    }
    
    public void setStudyAssays(Set<StudyAssay> studyAssays) {
        this.studyAssays = studyAssays;
    }
    public Set<StudyDesign> getStudyDesigns() {
        return this.studyDesigns;
    }
    
    public void setStudyDesigns(Set<StudyDesign> studyDesigns) {
        this.studyDesigns = studyDesigns;
    }


   public boolean equals(Object other) {
         if ( (this == other ) ) return true;
		 if ( (other == null ) ) return false;
		 if ( !(other instanceof AbstractStudy) ) return false;
		 AbstractStudy castOther = ( AbstractStudy ) other; 
         
		 return ( (this.getName()==castOther.getName()) || ( this.getName()!=null && castOther.getName()!=null && this.getName().equals(castOther.getName()) ) );
   }
   
   public int hashCode() {
         int result = 17;
         
         
         
         
         
         result = 37 * result + ( getName() == null ? 0 : this.getName().hashCode() );
         
         
         
         
         return result;
   }   

public AbstractStudy generateClone() {
	AbstractStudy cloned = new AbstractStudy; 
    	   cloned.publication = this.publication;
    	   cloned.dbxref = this.dbxref;
    	   cloned.contact = this.contact;
    	   cloned.name = this.name;
    	   cloned.description = this.description;
    	   cloned.studyProperties = this.studyProperties;
    	   cloned.studyAssays = this.studyAssays;
    	   cloned.studyDesigns = this.studyDesigns;
	return cloned;
}


}


