package org.bench4q.master.domain.entity.plugin;

import java.util.Set;

import javax.persistence.CollectionTable;
import javax.persistence.Column;
import javax.persistence.ElementCollection;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.JoinColumn;
import javax.persistence.Table;


@Entity
@Table(name = "selectType")
public class SelectType extends ParamType {
	private int size;
	private Set<String> options;

	@Column(name = "size")
	public int getSize() {
		return size;
	}

	public void setSize(int size) {
		this.size = size;
	}

	@ElementCollection(fetch = FetchType.EAGER)
	@CollectionTable(name = "selectOptions", joinColumns = @JoinColumn(name = "select_id"))
	@Column(name = "selectOption", nullable = false)
	public Set<String> getOptions() {
		return options;
	}

	public void setOptions(Set<String> options) {
		this.options = options;
	}

}
