without inheritance how do I support this simple model

21 views
Skip to first unread message

Johnny TwoShoes

unread,
Feb 9, 2016, 5:16:51 AM2/9/16
to Realm Java
Hello

I have a list of different objects, how would I model this with Realm ( without inheritance) :

{

"events":[  

      {  

         "event_id":"xax125",

         "event_data":{  

            “name”:"fred”,

            “age”:”27”,

         },

         "event_action":"new",

         "event_type”:"human"

      },

      {  

         "event_id":1,

         "event_data":{  

            “size”:”10 foot",

            “color”:"red"

         },

         "event_action":"update",

         "event_type”:"door"

      },

      {  

         "event_id":2,

         "event_data":{  

            “color":"red",

            “weight”:"5kg"

         },

         "event_action":"update",

         "event_type”:"book"

      }

   ]

}


thanks in advance


???

Reply all
Reply to author
Forward
0 new messages