22
33import java .io .Serializable ;
44
5- import io .asfjava .ui .core .form .Index ;
5+ import io .asfjava .ui .core .form .CheckBox ;
6+ import io .asfjava .ui .core .form .ComboBox ;
7+ import io .asfjava .ui .core .form .Number ;
68import io .asfjava .ui .core .form .Password ;
9+ import io .asfjava .ui .core .form .RadioBox ;
10+ import io .asfjava .ui .core .form .Tab ;
11+ import io .asfjava .ui .core .form .TextArea ;
712import io .asfjava .ui .core .form .TextField ;
813
914public class DemoForm implements Serializable {
1015
11- @ Index ( 3 )
12- @ TextField (title = "Personal Website" )
16+
17+ @ TextField (title = "Pesonal Website" , fieldAddonLeft = "http://" , description = "This is TextField with fieldAddonLeft " )
1318 private String webSite ;
14-
15- @ Index (2 )
16- @ TextField (title = "Your Github Mail" )
19+
20+ @ TextField (title = "Your Github Mail" ,fieldAddonRight ="@github.com" , description = "This is TextField with fieldAddonRight" )
1721 private String gitHub ;
18-
19- @ Index ( 4 )
20- @ Password (title = "Password" )
22+
23+ // @Tab(title = "Contact", index = 2 )
24+ @ Password (title = "Password" , placeHolder = "Please set you password" , description = "This is password" )
2125 private String password ;
2226
23- @ Index ( 0 )
24- @ TextField (title = "First Name" )
27+ @ Tab ( title = "Info" , index = 1 )
28+ @ TextField (title = "First Name" , placeHolder = "Your first name" , description = "This is a description for your first name field" )
2529 private String firstName ;
2630
27- // @Tab(title = "Info", index = 1)
28- // @TextField(title = "Last Name", placeHolder = "Your last name")
29- // private String lastName;
30- //
31- // @Tab(title = "Contact", index = 2)
32- // @TextField(title = "eMail", placeHolder = "Your email", pattern =
33- // "^\\S+@\\S+$", validationMessage = "Your mail must be in this format
34- // jhondoe@example.com", description = "This is Text Field with pattern and
35- // validation message")
36- // private String email;
37- //
38- // @Tab(title = "Additional Info", index = 3)
39- // @Number(title = "Number of children", placeHolder = "Number of children",
40- // description = "This is a number")
41- // private Integer number;
42- //
43- //
44- // @Tab(title = "Info", index = 1)
45- // @ComboBox(title = "Gender", titleMap = GenderTitleMap.class)
46- // private String gender;
47- //
48- //// @Tab(title = "Additional Info", index = 3)
49- // @ComboBox(title = "Currency", values = { "euro", "dollar" })
50- // private String currency;
51- //
52- // @Tab(title = "Additional Info", index = 3)
53- // @RadioBox(title = "Civil State", titleMap = CivilStateTitelsMap.class)
54- // private String civilState;
55- //
56- //// @Tab(title = "Contact", index = 2)
57- // @TextArea(title = "Address", placeHolder = "Fill your address please",
58- // description = "This is textarea")
59- // private String address;
60-
61- // @Tab(title = "Additional Info", index = 3)
62- // @CheckBox(title = "Color", values = { "red", "bleu", "green" },
63- // defaultvalue = "red")
64- // private String color;
31+ // @Tab(title = "Info", index = 1)
32+ @ TextField (title = "Last Name" , placeHolder = "Your last name" )
33+ private String lastName ;
34+
35+ @ Tab (title = "Contact" , index = 2 )
36+ @ TextField (title = "eMail" , placeHolder = "Your email" , pattern = "^\\ S+@\\ S+$" , validationMessage = "Your mail must be in this format jhondoe@example.com" , description = "This is Text Field with pattern and validation message" )
37+ private String email ;
38+
39+ @ Tab (title = "Additional Info" , index = 3 )
40+ @ Number (title = "Number of children" , placeHolder = "Number of children" , description = "This is a number" )
41+ private Integer number ;
42+
43+
44+ @ Tab (title = "Info" , index = 1 )
45+ @ ComboBox (title = "Gender" , titleMap = GenderTitleMap .class )
46+ private String gender ;
47+
48+ // @Tab(title = "Additional Info", index = 3)
49+ @ ComboBox (title = "Currency" , values = { "euro" , "dollar" })
50+ private String currency ;
51+
52+ @ Tab (title = "Additional Info" , index = 3 )
53+ @ RadioBox (title = "Civil State" , titleMap = CivilStateTitelsMap .class )
54+ private String civilState ;
55+
56+ // @Tab(title = "Contact", index = 2)
57+ @ TextArea (title = "Address" , placeHolder = "Fill your address please" , description = "This is textarea" )
58+ private String address ;
59+
60+ @ Tab (title = "Additional Info" , index = 3 )
61+ @ CheckBox (title = "Color" , values = { "red" , "bleu" , "green" }, defaultvalue = "red" )
62+ private String color ;
63+
64+ public String getFirstName () {
65+ return firstName ;
66+ }
6567
6668 public void setFirstName (String firstName ) {
6769 this .firstName = firstName ;
6870 }
6971
70- // public String getLastName() {
71- // return lastName;
72- // }
73- //
74- // public void setEmail(String eMail) {
75- // this.email = eMail;
76- // }
77- //
78- // public String getEmail() {
79- // return email;
80- // }
72+ public String getLastName () {
73+ return lastName ;
74+ }
8175
76+ public void setEmail (String eMail ) {
77+ this .email = eMail ;
78+ }
79+
80+ public String getEmail () {
81+ return email ;
82+ }
83+
8284 public void setGitHub (String github ) {
8385 this .gitHub = github ;
8486 }
8587
8688 public String getGitHub () {
8789 return gitHub ;
8890 }
89-
91+
9092 public void setWebSite (String website ) {
9193 this .webSite = website ;
9294 }
@@ -95,20 +97,17 @@ public String getWebSite() {
9597 return webSite ;
9698 }
9799
98- public String getFirstName () {
99- return firstName ;
100+ public void setLastName (String lastName ) {
101+ this .lastName = lastName ;
102+ }
103+
104+ public Integer getNumber () {
105+ return number ;
106+ }
107+
108+ public void setNumber (Integer number ) {
109+ this .number = number ;
100110 }
101- // public void setLastName(String lastName) {
102- // this.lastName = lastName;
103- // }
104- //
105- // public Integer getNumber() {
106- // return number;
107- // }
108- //
109- // public void setNumber(Integer number) {
110- // this.number = number;
111- // }
112111
113112 public String getPassword () {
114113 return password ;
@@ -118,33 +117,33 @@ public void setPassword(String password) {
118117 this .password = password ;
119118 }
120119
121- // public String getGender() {
122- // return gender;
123- // }
124- //
125- // public String getAddress() {
126- // return address;
127- // }
128- //
129- // public void setAddress(String address) {
130- // this.address = address;
131- // }
132- //
133- // public String getCivilState() {
134- // return civilState;
135- // }
136- //
137- // public void setCivilState(String civilState) {
138- // this.civilState = civilState;
139- // }
140- //
141- // public String getCurrency() {
142- // return currency;
143- // }
144-
145- // public String getColor() {
146- // return color;
147- // }
120+ public String getGender () {
121+ return gender ;
122+ }
123+
124+ public String getAddress () {
125+ return address ;
126+ }
127+
128+ public void setAddress (String address ) {
129+ this .address = address ;
130+ }
131+
132+ public String getCivilState () {
133+ return civilState ;
134+ }
135+
136+ public void setCivilState (String civilState ) {
137+ this .civilState = civilState ;
138+ }
139+
140+ public String getCurrency () {
141+ return currency ;
142+ }
143+
144+ public String getColor () {
145+ return color ;
146+ }
148147
149148 private static final long serialVersionUID = -5073515619469444978L ;
150149}
0 commit comments