001.package vaannila;
002.
003.import java.util.ArrayList;
004.
005.import com.opensymphony.xwork2.ActionSupport;
006.
007.public class RegisterAction extends ActionSupport {
008.
009. private String userName;
010.
011. private String password;
012.
013. private String gender;
014.
015. private String about;
016.
017. private String country;
018.
019. private ArrayList<Country> countryList;
020.
021. private String[] community;
022.
023. private ArrayList<String> communityList;
024.
025. private Boolean mailingList;
026.
027. public String populate() {
028.
029. countryList = new ArrayList<Country>();
030. countryList.add(new Country(1, "India"));
031. countryList.add(new Country(2, "USA"));
032. countryList.add(new Country(3, "France"));
033.
034. communityList = new ArrayList<String>();
035. communityList.add("Java");
036. communityList.add(".Net");
037. communityList.add("SOA");
038.
039. community = new String[]{"Java",".Net"};
040. mailingList = true;
041.
042. return "populate";
043. }
044.
045. public String execute() {
046. return SUCCESS;
047. }
048.
049. public String getUserName() {
050. return userName;
051. }
052.
053. public void setUserName(String userName) {
054. this.userName = userName;
055. }
056.
057. public String getPassword() {
058. return password;
059. }
060.
061. public void setPassword(String password) {
062. this.password = password;
063. }
064.
065. public String getGender() {
066. return gender;
067. }
068.
069. public void setGender(String gender) {
070. this.gender = gender;
071. }
072.
073. public String getAbout() {
074. return about;
075. }
076.
077. public void setAbout(String about) {
078. this.about = about;
079. }
080.
081. public String getCountry() {
082. return country;
083. }
084.
085. public void setCountry(String country) {
086. this.country = country;
087. }
088.
089. public ArrayList<Country> getCountryList() {
090. return countryList;
091. }
092.
093. public void setCountryList(ArrayList<Country> countryList) {
094. this.countryList = countryList;
095. }
096.
097. public String[] getCommunity() {
098. return community;
099. }
100.
101. public void setCommunity(String[] community) {
102. this.community = community;
103. }
104.
105. public ArrayList<String> getCommunityList() {
106. return communityList;
107. }
108.
109. public void setCommunityList(ArrayList<String> communityList) {
110. this.communityList = communityList;
111. }
112.
113. public Boolean getMailingList() {
114. return mailingList;
115. }
116.
117. public void setMailingList(Boolean mailingList) {
118. this.mailingList = mailingList;
119. }
120.
121.}