public class Category  implements java.io.Serializable, Comparable<Category>{


     private int id;
     private String name;
     private int topcategory;
     private Set searchs = new HashSet(0);

    public Category() {
    }
	
    public Category(int id) {
        this.id = id;
    }
    public Category(int id, String name, int topcategory, Set searchs) {
       this.id = id;
       this.name = name;
       this.topcategory = topcategory;
       this.searchs = searchs;
    }
   
    public int getId() {
        return this.id;
    }
    
    public void setId(int id) {
        this.id = id;
    }
    public String getName() {
        return this.name;
    }
    
    public void setName(String name) {
        this.name = name;
    }
    public int getTopcategory() {
        return this.topcategory;
    }
    
    public void setTopcategory(int topcategory) {
        this.topcategory = topcategory;
    }
    public Set getSearchs() {
        return this.searchs;
    }
    
    public void setSearchs(Set searchs) {
        this.searchs = searchs;
    }

    @Override
    public String toString(){
        return this.getName();
    }

    @Override
    public int compareTo(Category o) {
        return this.getName().compareTo(o.getName());
    }
}
