[Tellico-users] how to use DBUS to load table-like values

miguel at rozsas.eng.br miguel at rozsas.eng.br
Wed Nov 13 12:13:30 UTC 2013

Thanks Robby !

That worked just fine !

And I think the current way to add rows to a table using "::" as
fields separator and "file://" for images are fine, just document it
And I was surprised that nobody used the dbus interface to load data
to tellico. I think that using XML/XSLT is much more complicate isn't
Using dbus is just a matter of sequences (in any order) of
setEntryValue (entryID, fieldName, value)

However, would be nice to have a int getEntryID (QString fieldName,
QString regex) to search the database before setting or updating it.
Now, my database is empty, so I don't have an immediate use for it, bu
in the future would be nice to search the database before any
modifications, to avoid duplicates or something like that.

And a dbus command to save the database after a long sequence of
setEntryValue, would make the things even more easy.

Anyway, thank you for your help. I am ready to create my script and
organize my private collection of movies I did with my family and
mostly of my baby son, over the years, as automatically as possible.

best regards,
Miguel Rozsas

2013/11/13 Robby Stephenson <robby at periapsis.org>:
> On 11/12/2013 10:06 AM, miguel at rozsas.eng.br wrote:
>> It is easy to add data to simple fields like text and numbers using
>> setEntryValue :
>> dbus org.kde.tellico /Collections org.kde.tellico.addEntry
>> dbus org.kde.tellico /Collections org.kde.tellico.setEntryValue 1
>> title "Teste 1"
>> qdbus org.kde.tellico /Collections org.kde.tellico.setEntryValue 1 medium
>> "DVD"
>> qdbus org.kde.tellico /Collections org.kde.tellico.setEntryValue 1 year
>> "2010"
>> My question is how to add data to the more complex fields, like tables
>> (i.e., cast which has 2 values) or images like in cover ?
> Table columns are separated by a double-colon "::". (it's an artifact of a
> long ago decisions, one that I never bothered to change)
> You can add table rows with addEntryValue, which appends new rows
> qdbus org.kde.tellico /Collections org.kde.tellico.addEntryValue 1 cast
> "name::role"
> qdbus org.kde.tellico /Collections org.kde.tellico.addEntryValue 1 cast
> "name2::role2"
> Right now, the only way to add images is just as a link, using a file (or
> remote) url
> qdbus org.kde.tellico /Collections org.kde.tellico.setEntryValue 1 cover
> "file:///home/robby/tmp/coverimage.jpg"
> You're actually the first person to really ask about using the DBUS
> interface, and ask you can tell, it's not very nice or easy to figure out.
> Let me know of your suggestions and I will do what I can to add them.
> Maybe having a "setTableRow" or "addImage" commands would be good.
> Robby

More information about the tellico-users mailing list