Learn what Felgo offers to help your business succeed. Start your free evaluation today! Felgo for Your Business

Forums

OverviewFelgo 3 Support (Qt 5) › How do I store my own type in Storage?

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #24143

    Jens

    I am trying to build an application where you make simple schedules. I created an Item called Activity and added some properties like ‘duration’ and ‘title,’ but I can’t seem to add this to a Storage object. I guess I am struggling a bit to understand what an ‘Item’ is. Is it just a normal class like in other OOP languages?

     

    How should I do if I want to have an ‘Activity’ type and store it in a cache?

    #24150

    Filippo

    Hi Jens,

     

    an Item is a QML Object which is drawn by the underlying system. It is the equivalent of a View or a Widget in other programming languages, so you can’t store it directly using Storage.

     

    The closest construct to an OOP Object is a JavaScript object. Here you can find how to store and retrieve a “fruit” object directly inside the Felgo Storage: https://felgo.com/doc/felgo-storage/#advanced-usage

Viewing 2 posts - 1 through 2 (of 2 total)

RSS feed for this thread

You must be logged in to reply to this topic.

Qt_Technology_Partner_RGB_475 Qt_Service_Partner_RGB_475_padded