Skip to content

Commit 9cf9489

Browse files
committed
Updated doc
1 parent d273b4c commit 9cf9489

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

README.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ A lite weight SharedPreference library which uses annotation processing to gener
88

99
```kotin
1010
class InecBox(context: Context) {
11+
12+
val TAG: String = "InecBox"
1113
1214
//Read item from JadeSharedPreference
1315
@ReadString("ballot")
@@ -22,7 +24,13 @@ class InecBox(context: Context) {
2224
}
2325
2426
fun readBallot(){
25-
Log.d(InecBox::class.simpleName, ballotPaper)
27+
Log.d(TAG, ballotPaper)
28+
}
29+
30+
//Listen to String changes in realtime
31+
@ReadString("ballot")
32+
fun readStringChanges(s: String){
33+
Log.d(TAG, s)
2634
}
2735
2836
}

0 commit comments

Comments
 (0)