package com.tarena.oss.rights.pojo;

import java.io.Serializable;
import java.util.HashSet;
import java.util.Set;

public class Rights implements Serializable, Comparable<Rights> {
	private Integer id;

	private String name;

	private String url;

	private Operation oper;

	private Set<Role> roles = new HashSet<Role>();
	
	public Set<Role> getRoles() {
		return roles;
	}

	public void setRoles(Set<Role> roles) {
		this.roles = roles;
	}

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Operation getOper() {
		return oper;
	}

	public void setOper(Operation oper) {
		this.oper = oper;
	}

	public String getUrl() {
		return url;
	}

	public void setUrl(String url) {
		this.url = url;
	}

	public int compareTo(Rights o) {
		return this.id.compareTo(o.id);
	}

}
