« Return to Thread: Format Plugin

Format Plugin

by Bjoern Ricks :: Rate this Message:

Reply to Author | View in Thread

Hello all,

I am trying to develop a new format plugin for tomboy notes and I am a
bit confused about what I have to implement now. Tomboy notes are stored
as XML files in a directory. At first I plan to sync them via file-sync
to another backup directory (It should be the easiest scenario). Finally
I want to sync my tomboy notes via syncml.

So my questions are:
Do I need a detector? In which case and how is the detector function
used by the opensync engine? E.g. xmlformat-doc only checks if the xml
declaration (<?xml ...?>) exists. In this case are all xml files
automatically parsed as xmlformat?
Which format should I use for osync_objformat_new ("plain","memo",
"note", ...) ?
Should I directly convert the xml tomboy notes to "xmlformat" or first
parse them to an internal struct (like xmlformat-doc) and in a next step
convert the struct to xmlformat?

Additionally the use of some functions is unclear to me.
OSyncFormatCompareFunc:
docs/example-plugin/src/format.c says: "This function can be used to
compare two types of your formats.This is optional. For example, you can
only provide a conversion from and to the xml format and let all the
comparison be done there"
How is that meant?

OpenSyncFormatDuplicateFunc and OSyncFormatCopyFunc:
What is the difference between this two function and when should I use them?

OSyncFormatRevisionFunc:
This function is a big black hole to me. It is used e.g. in xmlformat.c
but what is the intention of this function?

Best Regards

--
/Bjoern Ricks

-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
Opensync-devel mailing list
Opensync-devel@...
https://lists.sourceforge.net/lists/listinfo/opensync-devel

 « Return to Thread: Format Plugin

LightInTheBox - Buy quality products at wholesale price!