Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Return remote object replica from remote call
Forum Updated to NodeBB v4.3 + New Features

Return remote object replica from remote call

Scheduled Pinned Locked Moved Unsolved General and Desktop
remoteobjectrpcipcqt5
1 Posts 1 Posters 375 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • H Offline
    H Offline
    heitho
    wrote on 12 Dec 2019, 19:38 last edited by heitho
    #1

    I'm trying to setup a remote object for a given class.
    The class returns a pointer to internal objects.

    class A
    {
    ...
        func(){ };
    }
    class B
    {
    std::vector<A> AObjects;
    ...
        A *addObject(){}
    }
    

    I created the rep file like this

    class A
    {
        SLOT(func())
    }
    class B
    {
        SLOT(A* addObject())
    }
    

    This causes errors because the generated code tries to serialize A to transfer it to the cient/replica side.
    What I want is a RemoteObject of A to get transferred to call func remotely from the client side.
    The number of A Object depends on the remote calls of addObject.

    Is there a way to get the such a system with qt remote objects?

    One way I could imagine is to set the returntype in B to the generated Replica class.

    class A
    {
        SLOT(func())
    }
    class B
    {
        SLOT(AReplica addObject())
    }
    

    But then the generated code must be available also at server side and the headers need to be in the right inclusion order...
    But replica objects are not serializable either.

    1 Reply Last reply
    0

    1/1

    12 Dec 2019, 19:38

    • Login

    • Login or register to search.
    1 out of 1
    • First post
      1/1
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved