summaryrefslogtreecommitdiff
path: root/development/pim/pimpaper/seperation.tex
Unidiff
Diffstat (limited to 'development/pim/pimpaper/seperation.tex') (more/less context) (show whitespace changes)
-rw-r--r--development/pim/pimpaper/seperation.tex66
1 files changed, 66 insertions, 0 deletions
diff --git a/development/pim/pimpaper/seperation.tex b/development/pim/pimpaper/seperation.tex
new file mode 100644
index 0000000..544d5c1
--- a/dev/null
+++ b/development/pim/pimpaper/seperation.tex
@@ -0,0 +1,66 @@
1\section{Components of Opie PIM}
2
3\subsection{The Record}
4With our API everything is based on a OPimRecord, this record
5got a Identifier which is unique to the Backend it belongs, it is
6also possible to assign a new Unique Identifier (uid) on a newly
7created OPimRecord.\\
8The OPimRecord allows to assign Categories this record is in, to get
9a Rich Text summary of the content of the Record and finally to match
10the content of the Record with a regular expression.
11
12\subsection{The Frontend}
13Opie PIM got Frontends to access Todos, Events and Addressees. Using
14the default Constructor of either OTodoAccess, ODatebookAccess or
15OContactAccess uses the default data. These Access methods offer
16the common load, save, clear, reload methods and have all in common
17to query for an example record, sort a list of records for specific
18characteristics, and to match the content against a regular expression
19 and give access to the Records inside the database/storage.\\
20The Frontend provide a value based Interface and operates on Records
21that inherit from OPimRecord and add extra task specific methods to it.
22
23\subsection{ORecordList and Iterator}
24The result of a query or the content of the database is a ORecordList.
25To iterate over a ORecordList you can use the Iterator. The Iterators
26behaves like the Iterators found in Qt and on dereferencing you get
27the reference to the record. Internally the record is fetched just
28in time. This delayed loading allows to exploit full power of the specific
29Backend.
30
31
32\subsection{The Backend}
33The Backend is a template based interface that operates on OPimRecord
34inherited data types. To implement the delayed loading the Backends
35Implementation return only a list of UIDs and these get converted
36to a OPimRecordList<T> by the Frontend.
37
38\subsection{The cache and read ahead}
39To speed up the repeated lookup of records, specially when iterating
40over the OPimRecordList we've a cache in the Frontend which is filled
41by the Backend and specially in the iterator case the Backend
42can do a read ahead to fill the cache.
43
44\subsection{Backend vs. Frontend}
45The Frontend is meant to be used by the normal API user to access
46and query the Records and to save it with different Backend to
47a different file if needed.
48The Backend is used to implement concrete storage such as XML, VCF
49and SQL and exploit possible features of the chosen storage. For example
50a SQL Backend can use the power of query, lookup, sorting of the database
51and do true delayed loading of records whereas the XML resource on
52a simple file-system normally can't (XMLLiveConnect on ReiserFS). On remote
53Backends such as LDAP one might want to use delayed initialisation and
54fetching of records as well. Due the clean separation of Frontend and Backend
55this is possible but the ease of development and deployment
56of both Backends and Frontend remain.
57
58\subsection{Occurrences}
59A Frontend/Backend can be queried to include OPimRecords for a
60period of time. Traditionally this only applies to Events but
61with the Opie1.2 revision of PIM this can also be applied to
62Todo, Address and Notes.
63It behaves similar to OPimRecordList and supports the delayed
64loading of Records.
65
66%TODO implement it.... :}