Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit fd6c1da1 authored by alejandro's avatar alejandro Committed by Mario Danic
Browse files

Tag was Added to RichObject

parent 8ffa1a58
Loading
Loading
Loading
Loading
+9 −0
Original line number Diff line number Diff line
@@ -36,6 +36,7 @@ public class RichObject {
    String name;
    String path;
    String link;
    String tag;

    public String getType() {
        return type;
@@ -76,4 +77,12 @@ public class RichObject {
    public void setLink(String link) {
        this.link = link;
    }

    public String getTag() {
        return tag;
    }

    public void setTag(String tag) {
        this.tag = tag;
    }
}
+3 −2
Original line number Diff line number Diff line
@@ -70,16 +70,17 @@ public class RichSubjectTypeAdapter extends TypeAdapter<RichSubject> {
        while (in.hasNext()) {
            String name = in.nextName();
            if (name != null && !name.isEmpty()) {
                richSubject.getRichObjectList().add(readObject(in));
                richSubject.getRichObjectList().add(readObject(name,in));
            }
        }
    }



    RichObject readObject(JsonReader in) throws IOException {
    RichObject readObject(String tag,JsonReader in) throws IOException {
        in.beginObject();
        RichObject richObject = new RichObject();
        richObject.setTag(tag);
        while (in.hasNext()) {
            String name = in.nextName();
            if ("type".contentEquals(name))