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. [SOLVED]QSqlTableModel subclass
QtWS25 Last Chance

[SOLVED]QSqlTableModel subclass

Scheduled Pinned Locked Moved General and Desktop
qsqltaqmodelidex
4 Posts 2 Posters 1.6k 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.
  • G Offline
    G Offline
    GrahamL
    wrote on 21 May 2015, 14:35 last edited by GrahamL
    #1

    Hi
    I am developing a subclass from QSqlTableModel and would appreciate anyone who could tell me what type of object would be returned by calling internalPointer on a QModelIndex

    Thanks in advance

    1 Reply Last reply
    0
    • M Offline
      M Offline
      mcosta
      wrote on 21 May 2015, 15:01 last edited by
      #2

      @GrahamL said:

      internalPointer

      internalPointer store a pointer to the internal structure of the model; you could check the Qt sources to verify the exact type.

      Just to talk, why do you need to access to these data?

      Once your problem is solved don't forget to:

      • Mark the thread as SOLVED using the Topic Tool menu
      • Vote up the answer(s) that helped you to solve the issue

      You can embed images using (http://imgur.com/) or (http://postimage.org/)

      G 1 Reply Last reply 22 May 2015, 07:37
      0
      • M mcosta
        21 May 2015, 15:01

        @GrahamL said:

        internalPointer

        internalPointer store a pointer to the internal structure of the model; you could check the Qt sources to verify the exact type.

        Just to talk, why do you need to access to these data?

        G Offline
        G Offline
        GrahamL
        wrote on 22 May 2015, 07:37 last edited by
        #3

        @mcosta
        I am just trying to gain a full understanding of the model view architecture
        I had an example that used a custom item model and that example uses internalPointer to get the underlying data

        1 Reply Last reply
        0
        • M Offline
          M Offline
          mcosta
          wrote on 22 May 2015, 07:58 last edited by
          #4

          Hi,

          internalPointer() is basically used when you use createIndex().
          As I said the internal structure is not specified in the documentation; so if you want to understand the exact implementation you have to have a look in the Qt sources

          Once your problem is solved don't forget to:

          • Mark the thread as SOLVED using the Topic Tool menu
          • Vote up the answer(s) that helped you to solve the issue

          You can embed images using (http://imgur.com/) or (http://postimage.org/)

          1 Reply Last reply
          0

          1/4

          21 May 2015, 14:35

          • Login

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