Skip to content

Commit 7efcfdd

Browse files
committed
Updated working with r20266
1 parent 9275e9d commit 7efcfdd

File tree

4 files changed

+15
-20
lines changed

4 files changed

+15
-20
lines changed

README.md

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -49,15 +49,10 @@ Take a look at the unit tests to get an idea of how you can use it.
4949

5050
----
5151

52-
## 2. Experimental :Using reflection to serialize from a real class instance to JSON
52+
## 2. Experimental Using reflection to serialize from a real class instance to JSON
5353

5454
(Requires use of a the experimental `mirrors` branch)
5555

56-
dependencies:
57-
json_object:
58-
git:
59-
url: git://github.com/chrisbu/dartwatch-JsonObject.git
60-
ref: mirrors
6156

6257
Use `objectToJson(myObj)` to return a future containing the serialized string.
6358

lib/json_object.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/* (C) 2012 Chris Buckett (chrisbuckett@gmail.com)
1+
/* (C) 2013 Chris Buckett (chrisbuckett@gmail.com)
22
* Released under the MIT licence
33
* See LICENCE file
44
* http://github.com/chrisbu/dartwatch-JsonObject

pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: json_object
2-
version: 1.0.11
2+
version: 1.0.12
33
author: Chris Buckett <chrisbuckett@gmail.com>
44
description: Allow use of JSON Maps in dot notation format
55
homepage: https://github.com/chrisbu/dartwatch-JsonObject

test/test_todo_vo.dart

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -39,18 +39,18 @@ class _TodoVOImpl extends JsonObject implements TodoVO {
3939
String toJson() {
4040

4141
StringBuffer buffer = new StringBuffer();
42-
buffer.add('{');
43-
buffer.add('"id":"'); // add the missing "
44-
buffer.add(id);
45-
buffer.add('", '); // add the missing "
46-
47-
buffer.add('"title":"');
48-
buffer.add( title );
49-
buffer.add('", ');
50-
51-
buffer.add('"completed":');
52-
buffer.add(completed.toString());
53-
buffer.add('}');
42+
buffer.write('{');
43+
buffer.write('"id":"'); // add the missing "
44+
buffer.write(id);
45+
buffer.write('", '); // add the missing "
46+
47+
buffer.write('"title":"');
48+
buffer.write( title );
49+
buffer.write('", ');
50+
51+
buffer.write('"completed":');
52+
buffer.write(completed.toString());
53+
buffer.write('}');
5454

5555
print(buffer.toString()); // add a print for debugging
5656
return buffer.toString();

0 commit comments

Comments
 (0)