Show Option.java syntax highlighted
package com.witfriend.apollo.domain;
import java.util.HashMap;
import java.util.Map;
import com.witfriend.zeus.domain.BaseObject;
/**
* DOCUMENT ME!
* @author wangyz
* @since 2006.10.04
* @version $Id$
*/
public class Option extends BaseObject {
private static final long serialVersionUID = -1187799029807474500L;
private String name;
private Integer point;
private Choice choice;
public Choice getChoice() {
if(choice == null) {
setChoice(new Choice());
}
return choice;
}
public void setChoice(Choice choice) {
this.choice = choice;
}
public String getName() {
return name;
}
public void setName(String value) {
this.name = value;
}
public Integer getPoint() {
return point;
}
public void setPoint(Integer point) {
this.point = point;
}
@Override
public Map<String, Object> getNaturalId() {
Map<String, Object> map = new HashMap<String, Object>();
map.put("name", getName());
map.put("choice", getChoice());
return map;
}
}
See more files for this project here