Skip to content

Instantly share code, notes, and snippets.

@wendal
Created July 16, 2012 11:00
Show Gist options
  • Save wendal/3122132 to your computer and use it in GitHub Desktop.
Save wendal/3122132 to your computer and use it in GitHub Desktop.
简单的List嵌套
class ListList {
private List<Object[]> list = new ArrayList<Object[]>();
public void add(Object ...objs) {
list.add(objs);
}
public String toJson(JsonFormat format) {
return Json.toJson(list, format);
}
public String toString() {
return list.toString();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment