Subversion Repositories bacoAlunos

Rev

Rev 1779 | Rev 1782 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1779 Rev 1780
Line 45... Line 45...
45
            .include("funcionarioRole",CourseSchoolImpl.class)
45
            .include("funcionarioRole",CourseSchoolImpl.class)
46
            .include("studentRole",CourseSchoolImpl.class)
46
            .include("studentRole",CourseSchoolImpl.class)
47
            .include("teacherRole",CourseSchoolImpl.class)
47
            .include("teacherRole",CourseSchoolImpl.class)
48
            .create();
48
            .create();
49
 
49
 
50
    public 1.5.0/docs/api/java/lang/String.html">String toJson() throws 1.5.0/docs/api/java/io/IOException.html">IOException
50
    public 1.5.0/docs/api/java/lang/String.html">String toJson()  {
51
    {
-
 
52
        return courseSchoolGenson.serialize(this);
51
        return courseSchoolGenson.serialize(this);
53
    }
52
    }
54
 
53
 
55
    public static 1.5.0/docs/api/java/lang/String.html">String toJson(ArrayList<CourseSchool> schools) throws 1.5.0/docs/api/java/io/IOException.html">IOException
54
    public static 1.5.0/docs/api/java/lang/String.html">String toJson(ArrayList<CourseSchool> schools) throws 1.5.0/docs/api/java/io/IOException.html">IOException
56
    {
55
    {
Line 59... Line 58...
59
 
58
 
60
    public static CourseSchoolImpl loadFromJson(1.5.0/docs/api/java/lang/String.html">String json) throws 1.5.0/docs/api/java/io/IOException.html">IOException {
59
    public static CourseSchoolImpl loadFromJson(1.5.0/docs/api/java/lang/String.html">String json) throws 1.5.0/docs/api/java/io/IOException.html">IOException {
61
        return courseSchoolGenson.deserialize(json, CourseSchoolImpl.class);
60
        return courseSchoolGenson.deserialize(json, CourseSchoolImpl.class);
62
    }
61
    }
63
 
62
 
64
    public JSONObject toJsonObject() throws 1.5.0/docs/api/java/io/IOException.html">IOException, JSONException {
63
    public JSONObject toJsonObject() throws  JSONException {
65
        return new JSONObject(toJson());
64
        return new JSONObject(toJson());
66
    }
65
    }
67
}
66
}