aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorReinier Zwitserloot <reinier@tipit.to>2009-07-11 11:34:29 +0200
committerReinier Zwitserloot <reinier@tipit.to>2009-07-11 11:34:29 +0200
commit98382c6640798846efcc11113116cb46fb820595 (patch)
tree435ee0dad34995b5d6bb1ae53fd4e6f3207caf93
parentf84f3a1bc8407160b82580300d2a58fd8c66aaa1 (diff)
downloadlombok-98382c6640798846efcc11113116cb46fb820595.tar.gz
lombok-98382c6640798846efcc11113116cb46fb820595.tar.bz2
lombok-98382c6640798846efcc11113116cb46fb820595.zip
Added examples with pre and post lombok conversion for the website.
-rw-r--r--usage_examples/GetterSetterExample_post.jpage20
-rw-r--r--usage_examples/GetterSetterExample_pre.jpage12
-rw-r--r--website/features/GetterSetterExample.pngbin0 -> 76859 bytes
3 files changed, 32 insertions, 0 deletions
diff --git a/usage_examples/GetterSetterExample_post.jpage b/usage_examples/GetterSetterExample_post.jpage
new file mode 100644
index 00000000..b0921b86
--- /dev/null
+++ b/usage_examples/GetterSetterExample_post.jpage
@@ -0,0 +1,20 @@
+public class GetterSetterExample {
+ private int age = 10;
+ private String name;
+
+ @Override public String toString() {
+ return String.format("%s (age: %d)", age, name);
+ }
+
+ public int getAge() {
+ return age;
+ }
+
+ public void setAge(int age) {
+ this.age = age;
+ }
+
+ protected void setName(String name) {
+ this.name = name;
+ }
+}
diff --git a/usage_examples/GetterSetterExample_pre.jpage b/usage_examples/GetterSetterExample_pre.jpage
new file mode 100644
index 00000000..0da1d2e2
--- /dev/null
+++ b/usage_examples/GetterSetterExample_pre.jpage
@@ -0,0 +1,12 @@
+import lombok.AccessLevel;
+import lombok.Getter;
+import lombok.Setter;
+
+public class GetterSetterExample {
+ private @Getter @Setter int age = 10;
+ private @Setter(AccessLevel.PROTECTED) String name;
+
+ @Override public String toString() {
+ return String.format("%s (age: %d)", age, name);
+ }
+}
diff --git a/website/features/GetterSetterExample.png b/website/features/GetterSetterExample.png
new file mode 100644
index 00000000..785a5984
--- /dev/null
+++ b/website/features/GetterSetterExample.png
Binary files differ