mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-08-21 06:33:18 +00:00
see ChangeLog
Monotone-Revision: 9054022ef1ca8aeba6e34842d27d9b94ce002b89 Monotone-Author: dev-unix.inverse.qc.ca Monotone-Date: 2006-06-15T19:34:10 Monotone-Branch: ca.inverse.sogo
This commit is contained in:
@@ -0,0 +1,482 @@
|
||||
GNU LIBRARY GENERAL PUBLIC LICENSE
|
||||
Version 2, June 1991
|
||||
|
||||
Copyright (C) 1991 Free Software Foundation, Inc.
|
||||
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
[This is the first released version of the library GPL. It is
|
||||
numbered 2 because it goes with version 2 of the ordinary GPL.]
|
||||
|
||||
Preamble
|
||||
|
||||
The licenses for most software are designed to take away your
|
||||
freedom to share and change it. By contrast, the GNU General Public
|
||||
Licenses are intended to guarantee your freedom to share and change
|
||||
free software--to make sure the software is free for all its users.
|
||||
|
||||
This license, the Library General Public License, applies to some
|
||||
specially designated Free Software Foundation software, and to any
|
||||
other libraries whose authors decide to use it. You can use it for
|
||||
your libraries, too.
|
||||
|
||||
When we speak of free software, we are referring to freedom, not
|
||||
price. Our General Public Licenses are designed to make sure that you
|
||||
have the freedom to distribute copies of free software (and charge for
|
||||
this service if you wish), that you receive source code or can get it
|
||||
if you want it, that you can change the software or use pieces of it
|
||||
in new free programs; and that you know you can do these things.
|
||||
|
||||
To protect your rights, we need to make restrictions that forbid
|
||||
anyone to deny you these rights or to ask you to surrender the rights.
|
||||
These restrictions translate to certain responsibilities for you if
|
||||
you distribute copies of the library, or if you modify it.
|
||||
|
||||
For example, if you distribute copies of the library, whether gratis
|
||||
or for a fee, you must give the recipients all the rights that we gave
|
||||
you. You must make sure that they, too, receive or can get the source
|
||||
code. If you link a program with the library, you must provide
|
||||
complete object files to the recipients so that they can relink them
|
||||
with the library, after making changes to the library and recompiling
|
||||
it. And you must show them these terms so they know their rights.
|
||||
|
||||
Our method of protecting your rights has two steps: (1) copyright
|
||||
the library, and (2) offer you this license which gives you legal
|
||||
permission to copy, distribute and/or modify the library.
|
||||
|
||||
Also, for each distributor's protection, we want to make certain
|
||||
that everyone understands that there is no warranty for this free
|
||||
library. If the library is modified by someone else and passed on, we
|
||||
want its recipients to know that what they have is not the original
|
||||
version, so that any problems introduced by others will not reflect on
|
||||
the original authors' reputations.
|
||||
|
||||
Finally, any free program is threatened constantly by software
|
||||
patents. We wish to avoid the danger that companies distributing free
|
||||
software will individually obtain patent licenses, thus in effect
|
||||
transforming the program into proprietary software. To prevent this,
|
||||
we have made it clear that any patent must be licensed for everyone's
|
||||
free use or not licensed at all.
|
||||
|
||||
Most GNU software, including some libraries, is covered by the ordinary
|
||||
GNU General Public License, which was designed for utility programs. This
|
||||
license, the GNU Library General Public License, applies to certain
|
||||
designated libraries. This license is quite different from the ordinary
|
||||
one; be sure to read it in full, and don't assume that anything in it is
|
||||
the same as in the ordinary license.
|
||||
|
||||
The reason we have a separate public license for some libraries is that
|
||||
they blur the distinction we usually make between modifying or adding to a
|
||||
program and simply using it. Linking a program with a library, without
|
||||
changing the library, is in some sense simply using the library, and is
|
||||
analogous to running a utility program or application program. However, in
|
||||
a textual and legal sense, the linked executable is a combined work, a
|
||||
derivative of the original library, and the ordinary General Public License
|
||||
treats it as such.
|
||||
|
||||
Because of this blurred distinction, using the ordinary General
|
||||
Public License for libraries did not effectively promote software
|
||||
sharing, because most developers did not use the libraries. We
|
||||
concluded that weaker conditions might promote sharing better.
|
||||
|
||||
However, unrestricted linking of non-free programs would deprive the
|
||||
users of those programs of all benefit from the free status of the
|
||||
libraries themselves. This Library General Public License is intended to
|
||||
permit developers of non-free programs to use free libraries, while
|
||||
preserving your freedom as a user of such programs to change the free
|
||||
libraries that are incorporated in them. (We have not seen how to achieve
|
||||
this as regards changes in header files, but we have achieved it as regards
|
||||
changes in the actual functions of the Library.) The hope is that this
|
||||
will lead to faster development of free libraries.
|
||||
|
||||
The precise terms and conditions for copying, distribution and
|
||||
modification follow. Pay close attention to the difference between a
|
||||
"work based on the library" and a "work that uses the library". The
|
||||
former contains code derived from the library, while the latter only
|
||||
works together with the library.
|
||||
|
||||
Note that it is possible for a library to be covered by the ordinary
|
||||
General Public License rather than by this special one.
|
||||
|
||||
GNU LIBRARY GENERAL PUBLIC LICENSE
|
||||
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
||||
|
||||
0. This License Agreement applies to any software library which
|
||||
contains a notice placed by the copyright holder or other authorized
|
||||
party saying it may be distributed under the terms of this Library
|
||||
General Public License (also called "this License"). Each licensee is
|
||||
addressed as "you".
|
||||
|
||||
A "library" means a collection of software functions and/or data
|
||||
prepared so as to be conveniently linked with application programs
|
||||
(which use some of those functions and data) to form executables.
|
||||
|
||||
The "Library", below, refers to any such software library or work
|
||||
which has been distributed under these terms. A "work based on the
|
||||
Library" means either the Library or any derivative work under
|
||||
copyright law: that is to say, a work containing the Library or a
|
||||
portion of it, either verbatim or with modifications and/or translated
|
||||
straightforwardly into another language. (Hereinafter, translation is
|
||||
included without limitation in the term "modification".)
|
||||
|
||||
"Source code" for a work means the preferred form of the work for
|
||||
making modifications to it. For a library, complete source code means
|
||||
all the source code for all modules it contains, plus any associated
|
||||
interface definition files, plus the scripts used to control compilation
|
||||
and installation of the library.
|
||||
|
||||
Activities other than copying, distribution and modification are not
|
||||
covered by this License; they are outside its scope. The act of
|
||||
running a program using the Library is not restricted, and output from
|
||||
such a program is covered only if its contents constitute a work based
|
||||
on the Library (independent of the use of the Library in a tool for
|
||||
writing it). Whether that is true depends on what the Library does
|
||||
and what the program that uses the Library does.
|
||||
|
||||
1. You may copy and distribute verbatim copies of the Library's
|
||||
complete source code as you receive it, in any medium, provided that
|
||||
you conspicuously and appropriately publish on each copy an
|
||||
appropriate copyright notice and disclaimer of warranty; keep intact
|
||||
all the notices that refer to this License and to the absence of any
|
||||
warranty; and distribute a copy of this License along with the
|
||||
Library.
|
||||
|
||||
You may charge a fee for the physical act of transferring a copy,
|
||||
and you may at your option offer warranty protection in exchange for a
|
||||
fee.
|
||||
|
||||
2. You may modify your copy or copies of the Library or any portion
|
||||
of it, thus forming a work based on the Library, and copy and
|
||||
distribute such modifications or work under the terms of Section 1
|
||||
above, provided that you also meet all of these conditions:
|
||||
|
||||
a) The modified work must itself be a software library.
|
||||
|
||||
b) You must cause the files modified to carry prominent notices
|
||||
stating that you changed the files and the date of any change.
|
||||
|
||||
c) You must cause the whole of the work to be licensed at no
|
||||
charge to all third parties under the terms of this License.
|
||||
|
||||
d) If a facility in the modified Library refers to a function or a
|
||||
table of data to be supplied by an application program that uses
|
||||
the facility, other than as an argument passed when the facility
|
||||
is invoked, then you must make a good faith effort to ensure that,
|
||||
in the event an application does not supply such function or
|
||||
table, the facility still operates, and performs whatever part of
|
||||
its purpose remains meaningful.
|
||||
|
||||
(For example, a function in a library to compute square roots has
|
||||
a purpose that is entirely well-defined independent of the
|
||||
application. Therefore, Subsection 2d requires that any
|
||||
application-supplied function or table used by this function must
|
||||
be optional: if the application does not supply it, the square
|
||||
root function must still compute square roots.)
|
||||
|
||||
These requirements apply to the modified work as a whole. If
|
||||
identifiable sections of that work are not derived from the Library,
|
||||
and can be reasonably considered independent and separate works in
|
||||
themselves, then this License, and its terms, do not apply to those
|
||||
sections when you distribute them as separate works. But when you
|
||||
distribute the same sections as part of a whole which is a work based
|
||||
on the Library, the distribution of the whole must be on the terms of
|
||||
this License, whose permissions for other licensees extend to the
|
||||
entire whole, and thus to each and every part regardless of who wrote
|
||||
it.
|
||||
|
||||
Thus, it is not the intent of this section to claim rights or contest
|
||||
your rights to work written entirely by you; rather, the intent is to
|
||||
exercise the right to control the distribution of derivative or
|
||||
collective works based on the Library.
|
||||
|
||||
In addition, mere aggregation of another work not based on the Library
|
||||
with the Library (or with a work based on the Library) on a volume of
|
||||
a storage or distribution medium does not bring the other work under
|
||||
the scope of this License.
|
||||
|
||||
3. You may opt to apply the terms of the ordinary GNU General Public
|
||||
License instead of this License to a given copy of the Library. To do
|
||||
this, you must alter all the notices that refer to this License, so
|
||||
that they refer to the ordinary GNU General Public License, version 2,
|
||||
instead of to this License. (If a newer version than version 2 of the
|
||||
ordinary GNU General Public License has appeared, then you can specify
|
||||
that version instead if you wish.) Do not make any other change in
|
||||
these notices.
|
||||
|
||||
Once this change is made in a given copy, it is irreversible for
|
||||
that copy, so the ordinary GNU General Public License applies to all
|
||||
subsequent copies and derivative works made from that copy.
|
||||
|
||||
This option is useful when you wish to copy part of the code of
|
||||
the Library into a program that is not a library.
|
||||
|
||||
4. You may copy and distribute the Library (or a portion or
|
||||
derivative of it, under Section 2) in object code or executable form
|
||||
under the terms of Sections 1 and 2 above provided that you accompany
|
||||
it with the complete corresponding machine-readable source code, which
|
||||
must be distributed under the terms of Sections 1 and 2 above on a
|
||||
medium customarily used for software interchange.
|
||||
|
||||
If distribution of object code is made by offering access to copy
|
||||
from a designated place, then offering equivalent access to copy the
|
||||
source code from the same place satisfies the requirement to
|
||||
distribute the source code, even though third parties are not
|
||||
compelled to copy the source along with the object code.
|
||||
|
||||
5. A program that contains no derivative of any portion of the
|
||||
Library, but is designed to work with the Library by being compiled or
|
||||
linked with it, is called a "work that uses the Library". Such a
|
||||
work, in isolation, is not a derivative work of the Library, and
|
||||
therefore falls outside the scope of this License.
|
||||
|
||||
However, linking a "work that uses the Library" with the Library
|
||||
creates an executable that is a derivative of the Library (because it
|
||||
contains portions of the Library), rather than a "work that uses the
|
||||
library". The executable is therefore covered by this License.
|
||||
Section 6 states terms for distribution of such executables.
|
||||
|
||||
When a "work that uses the Library" uses material from a header file
|
||||
that is part of the Library, the object code for the work may be a
|
||||
derivative work of the Library even though the source code is not.
|
||||
Whether this is true is especially significant if the work can be
|
||||
linked without the Library, or if the work is itself a library. The
|
||||
threshold for this to be true is not precisely defined by law.
|
||||
|
||||
If such an object file uses only numerical parameters, data
|
||||
structure layouts and accessors, and small macros and small inline
|
||||
functions (ten lines or less in length), then the use of the object
|
||||
file is unrestricted, regardless of whether it is legally a derivative
|
||||
work. (Executables containing this object code plus portions of the
|
||||
Library will still fall under Section 6.)
|
||||
|
||||
Otherwise, if the work is a derivative of the Library, you may
|
||||
distribute the object code for the work under the terms of Section 6.
|
||||
Any executables containing that work also fall under Section 6,
|
||||
whether or not they are linked directly with the Library itself.
|
||||
|
||||
6. As an exception to the Sections above, you may also compile or
|
||||
link a "work that uses the Library" with the Library to produce a
|
||||
work containing portions of the Library, and distribute that work
|
||||
under terms of your choice, provided that the terms permit
|
||||
modification of the work for the customer's own use and reverse
|
||||
engineering for debugging such modifications.
|
||||
|
||||
You must give prominent notice with each copy of the work that the
|
||||
Library is used in it and that the Library and its use are covered by
|
||||
this License. You must supply a copy of this License. If the work
|
||||
during execution displays copyright notices, you must include the
|
||||
copyright notice for the Library among them, as well as a reference
|
||||
directing the user to the copy of this License. Also, you must do one
|
||||
of these things:
|
||||
|
||||
a) Accompany the work with the complete corresponding
|
||||
machine-readable source code for the Library including whatever
|
||||
changes were used in the work (which must be distributed under
|
||||
Sections 1 and 2 above); and, if the work is an executable linked
|
||||
with the Library, with the complete machine-readable "work that
|
||||
uses the Library", as object code and/or source code, so that the
|
||||
user can modify the Library and then relink to produce a modified
|
||||
executable containing the modified Library. (It is understood
|
||||
that the user who changes the contents of definitions files in the
|
||||
Library will not necessarily be able to recompile the application
|
||||
to use the modified definitions.)
|
||||
|
||||
b) Accompany the work with a written offer, valid for at
|
||||
least three years, to give the same user the materials
|
||||
specified in Subsection 6a, above, for a charge no more
|
||||
than the cost of performing this distribution.
|
||||
|
||||
c) If distribution of the work is made by offering access to copy
|
||||
from a designated place, offer equivalent access to copy the above
|
||||
specified materials from the same place.
|
||||
|
||||
d) Verify that the user has already received a copy of these
|
||||
materials or that you have already sent this user a copy.
|
||||
|
||||
For an executable, the required form of the "work that uses the
|
||||
Library" must include any data and utility programs needed for
|
||||
reproducing the executable from it. However, as a special exception,
|
||||
the source code distributed need not include anything that is normally
|
||||
distributed (in either source or binary form) with the major
|
||||
components (compiler, kernel, and so on) of the operating system on
|
||||
which the executable runs, unless that component itself accompanies
|
||||
the executable.
|
||||
|
||||
It may happen that this requirement contradicts the license
|
||||
restrictions of other proprietary libraries that do not normally
|
||||
accompany the operating system. Such a contradiction means you cannot
|
||||
use both them and the Library together in an executable that you
|
||||
distribute.
|
||||
|
||||
7. You may place library facilities that are a work based on the
|
||||
Library side-by-side in a single library together with other library
|
||||
facilities not covered by this License, and distribute such a combined
|
||||
library, provided that the separate distribution of the work based on
|
||||
the Library and of the other library facilities is otherwise
|
||||
permitted, and provided that you do these two things:
|
||||
|
||||
a) Accompany the combined library with a copy of the same work
|
||||
based on the Library, uncombined with any other library
|
||||
facilities. This must be distributed under the terms of the
|
||||
Sections above.
|
||||
|
||||
b) Give prominent notice with the combined library of the fact
|
||||
that part of it is a work based on the Library, and explaining
|
||||
where to find the accompanying uncombined form of the same work.
|
||||
|
||||
8. You may not copy, modify, sublicense, link with, or distribute
|
||||
the Library except as expressly provided under this License. Any
|
||||
attempt otherwise to copy, modify, sublicense, link with, or
|
||||
distribute the Library is void, and will automatically terminate your
|
||||
rights under this License. However, parties who have received copies,
|
||||
or rights, from you under this License will not have their licenses
|
||||
terminated so long as such parties remain in full compliance.
|
||||
|
||||
9. You are not required to accept this License, since you have not
|
||||
signed it. However, nothing else grants you permission to modify or
|
||||
distribute the Library or its derivative works. These actions are
|
||||
prohibited by law if you do not accept this License. Therefore, by
|
||||
modifying or distributing the Library (or any work based on the
|
||||
Library), you indicate your acceptance of this License to do so, and
|
||||
all its terms and conditions for copying, distributing or modifying
|
||||
the Library or works based on it.
|
||||
|
||||
10. Each time you redistribute the Library (or any work based on the
|
||||
Library), the recipient automatically receives a license from the
|
||||
original licensor to copy, distribute, link with or modify the Library
|
||||
subject to these terms and conditions. You may not impose any further
|
||||
restrictions on the recipients' exercise of the rights granted herein.
|
||||
You are not responsible for enforcing compliance by third parties to
|
||||
this License.
|
||||
|
||||
11. If, as a consequence of a court judgment or allegation of patent
|
||||
infringement or for any other reason (not limited to patent issues),
|
||||
conditions are imposed on you (whether by court order, agreement or
|
||||
otherwise) that contradict the conditions of this License, they do not
|
||||
excuse you from the conditions of this License. If you cannot
|
||||
distribute so as to satisfy simultaneously your obligations under this
|
||||
License and any other pertinent obligations, then as a consequence you
|
||||
may not distribute the Library at all. For example, if a patent
|
||||
license would not permit royalty-free redistribution of the Library by
|
||||
all those who receive copies directly or indirectly through you, then
|
||||
the only way you could satisfy both it and this License would be to
|
||||
refrain entirely from distribution of the Library.
|
||||
|
||||
If any portion of this section is held invalid or unenforceable under any
|
||||
particular circumstance, the balance of the section is intended to apply,
|
||||
and the section as a whole is intended to apply in other circumstances.
|
||||
|
||||
It is not the purpose of this section to induce you to infringe any
|
||||
patents or other property right claims or to contest validity of any
|
||||
such claims; this section has the sole purpose of protecting the
|
||||
integrity of the free software distribution system which is
|
||||
implemented by public license practices. Many people have made
|
||||
generous contributions to the wide range of software distributed
|
||||
through that system in reliance on consistent application of that
|
||||
system; it is up to the author/donor to decide if he or she is willing
|
||||
to distribute software through any other system and a licensee cannot
|
||||
impose that choice.
|
||||
|
||||
This section is intended to make thoroughly clear what is believed to
|
||||
be a consequence of the rest of this License.
|
||||
|
||||
12. If the distribution and/or use of the Library is restricted in
|
||||
certain countries either by patents or by copyrighted interfaces, the
|
||||
original copyright holder who places the Library under this License may add
|
||||
an explicit geographical distribution limitation excluding those countries,
|
||||
so that distribution is permitted only in or among countries not thus
|
||||
excluded. In such case, this License incorporates the limitation as if
|
||||
written in the body of this License.
|
||||
|
||||
13. The Free Software Foundation may publish revised and/or new
|
||||
versions of the Library General Public License from time to time.
|
||||
Such new versions will be similar in spirit to the present version,
|
||||
but may differ in detail to address new problems or concerns.
|
||||
|
||||
Each version is given a distinguishing version number. If the Library
|
||||
specifies a version number of this License which applies to it and
|
||||
"any later version", you have the option of following the terms and
|
||||
conditions either of that version or of any later version published by
|
||||
the Free Software Foundation. If the Library does not specify a
|
||||
license version number, you may choose any version ever published by
|
||||
the Free Software Foundation.
|
||||
|
||||
14. If you wish to incorporate parts of the Library into other free
|
||||
programs whose distribution conditions are incompatible with these,
|
||||
write to the author to ask for permission. For software which is
|
||||
copyrighted by the Free Software Foundation, write to the Free
|
||||
Software Foundation; we sometimes make exceptions for this. Our
|
||||
decision will be guided by the two goals of preserving the free status
|
||||
of all derivatives of our free software and of promoting the sharing
|
||||
and reuse of software generally.
|
||||
|
||||
NO WARRANTY
|
||||
|
||||
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
|
||||
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
|
||||
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
|
||||
OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
|
||||
KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
|
||||
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
|
||||
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||
|
||||
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
|
||||
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
|
||||
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
|
||||
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
|
||||
CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
|
||||
LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
|
||||
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
|
||||
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
|
||||
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
|
||||
DAMAGES.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
Appendix: How to Apply These Terms to Your New Libraries
|
||||
|
||||
If you develop a new library, and you want it to be of the greatest
|
||||
possible use to the public, we recommend making it free software that
|
||||
everyone can redistribute and change. You can do so by permitting
|
||||
redistribution under these terms (or, alternatively, under the terms of the
|
||||
ordinary General Public License).
|
||||
|
||||
To apply these terms, attach the following notices to the library. It is
|
||||
safest to attach them to the start of each source file to most effectively
|
||||
convey the exclusion of warranty; and each file should have at least the
|
||||
"copyright" line and a pointer to where the full notice is found.
|
||||
|
||||
<one line to give the library's name and a brief idea of what it does.>
|
||||
Copyright (C) <year> <name of author>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Library General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2 of the License, or (at your option) any later version.
|
||||
|
||||
This library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Library General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Library General Public
|
||||
License along with this library; if not, write to the Free
|
||||
Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
|
||||
MA 02111-1307, USA
|
||||
|
||||
Also add information on how to contact you by electronic and paper mail.
|
||||
|
||||
You should also get your employer (if you work as a programmer) or your
|
||||
school, if any, to sign a "copyright disclaimer" for the library, if
|
||||
necessary. Here is a sample; alter the names:
|
||||
|
||||
Yoyodyne, Inc., hereby disclaims all copyright interest in the
|
||||
library `Frob' (a library for tweaking knobs) written by James Random Hacker.
|
||||
|
||||
<signature of Ty Coon>, 1 April 1990
|
||||
Ty Coon, President of Vice
|
||||
|
||||
That's all there is to it!
|
||||
@@ -0,0 +1,4 @@
|
||||
Copyright (C) 2004 SKYRIX Software AG
|
||||
|
||||
|
||||
Contact: info@skyrix.com
|
||||
@@ -0,0 +1,269 @@
|
||||
2005-12-19 Marcus Mueller <znek@mulle-kybernetik.com>
|
||||
|
||||
* GNUMakefile.preamble: provide all necessary library dependencies
|
||||
for certain broken linkers - this won't harm platforms sporting
|
||||
more capable linkers (v0.9.33)
|
||||
|
||||
2005-08-01 Helge Hess <helge.hess@skyrix.com>
|
||||
|
||||
* added FHS installation (v0.9.32)
|
||||
|
||||
2005-07-26 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* sql: added missing priority quickfield to SQLite tables (v0.9.31)
|
||||
|
||||
2005-07-13 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* OCSContactFieldExtractor.m: do not crash if the content is not a
|
||||
proper property list, added ability to extract fields from a vCard
|
||||
(v0.9.30)
|
||||
|
||||
2005-07-12 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* added sql/profile-create.psql to create the user-profile database
|
||||
table (not strictly related to OCSContentStore)
|
||||
|
||||
2005-07-05 Marcus Mueller <znek@mulle-kybernetik.com>
|
||||
|
||||
* iCalEntityObject+OCS.m: fixed stupid extraction bug (v0.9.29)
|
||||
|
||||
2005-07-05 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* v0.9.28
|
||||
|
||||
* added test_quick_extract.m tool to test the quick-field extraction
|
||||
|
||||
* OCSiCalFieldExtractor.m: properly deal with the iCal parser returning
|
||||
just the iCalEvent
|
||||
|
||||
2005-07-04 Marcus Mueller <znek@mulle-kybernetik.com>
|
||||
|
||||
* v0.9.27
|
||||
|
||||
* iCalEntityObject+OCS.[hm]: new category used by OCSiCalFieldExtractor
|
||||
|
||||
* OCSiCalFieldExtractor.m: extract priority from iCal event
|
||||
|
||||
* appointment.ocs: added priority
|
||||
|
||||
* sql/generate-folderinfo-sql-for-users.sh: added priority quick field
|
||||
|
||||
2005-03-20 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* moved most of the code to SOPE 4.5 sope-gdl1/GDLContentStore
|
||||
(v0.9.26)
|
||||
|
||||
2005-03-07 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* appointment.ocs: added missing 'partstates' field (v0.9.25)
|
||||
|
||||
2005-03-04 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* v0.9.24
|
||||
|
||||
* ocs_gensql.m: started tool to create SQL CREATE from ocs model file
|
||||
|
||||
* OCSFolderType.m: small change to the factory API, changed to use
|
||||
NGResourceLocator
|
||||
|
||||
2005-03-03 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* OCSFolderManager.m: fixed a bug in subfolder listing (v0.9.23)
|
||||
|
||||
2005-03-01 Marcus Mueller <znek@mulle-kybernetik.com>
|
||||
|
||||
* v0.9.22
|
||||
|
||||
* appointment.ocs: added 'cycleenddate' and 'cycleinfo' to address
|
||||
previous performance issues
|
||||
|
||||
* OCSiCalFieldExtractor.m: set 'cycleenddate' and 'cycleinfo' for
|
||||
recurrent events. Reverted setting of 'enddate' to the previous
|
||||
behaviour since 'cycleenddate' is dedicated to the task now
|
||||
|
||||
* iCalRepeatableEntityObject+OCS.[hm]: new category used by the
|
||||
OCSiCalFieldExtractor to extract cycleInfo in an appropriate format
|
||||
|
||||
* sql/generate-folderinfo-sql-for-users.sh,
|
||||
sql/foldertablecreate-helge-privcal.psql,
|
||||
sql/foldertablecreate-helge-privcal.sqlite,
|
||||
sql/generate-folderinfo-sql-for-users-sqlite.sh: adjusted to new
|
||||
schema
|
||||
|
||||
2005-03-01 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* OCSFolder.m: added support for storing content and quick info in
|
||||
the same table (untested) (v0.9.21)
|
||||
|
||||
2005-02-21 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* v0.9.20
|
||||
|
||||
* OCSFolderManager.m: removed quoting of SQL table and column names
|
||||
(breaks with SQLite and isn't necessary for PG), fixed URL pooling
|
||||
for SQLite
|
||||
|
||||
* NSURL+OCS.m: use tablename for last path component
|
||||
|
||||
2005-02-12 Marcus Mueller <znek@mulle-kybernetik.com>
|
||||
|
||||
* OCSiCalFieldExtractor.m: uses new iCalEvent API to determine correct
|
||||
'enddate' for recurrent events. This is an optimization which can
|
||||
save quite some time for complex rules. (v0.9.19)
|
||||
|
||||
2004-12-17 Marcus Mueller <znek@mulle-kybernetik.com>
|
||||
|
||||
* v0.9.18
|
||||
|
||||
* OCSiCalFieldExtractor.m: extract participants' state
|
||||
|
||||
* sql/generate-folderinfo-sql-for-user.sh, sql/appointment-create.psql,
|
||||
sql/foldertablecreate-helge-privcal.psql: updated with new schema.
|
||||
|
||||
2004-12-15 Marcus Mueller <znek@mulle-kybernetik.com>
|
||||
|
||||
* OCSiCalFieldExtractor.m: partmails + cn's are concatenated by '\n'
|
||||
now - this directly eliminates any ambiguities. Also, instead of
|
||||
using 'email' for partmails and orgmail, the extractor uses the
|
||||
'rfc822Email' value which strips away any preceeding 'mailto:'
|
||||
prefix, compacting the representation and speeding up comparison.
|
||||
Also, "iscycle", "isallday" and "isopaque" are now provided by
|
||||
NGiCal and thus always extracted (v0.9.17)
|
||||
|
||||
2004-12-13 Marcus Mueller <znek@mulle-kybernetik.com>
|
||||
|
||||
* sql/generate-folderinfo-sql-for-user.sh: fixed critical error in
|
||||
Contacts folder_info, type was 'Appointment' but MUST be 'Contact'
|
||||
(v0.9.16)
|
||||
|
||||
2004-12-10 Marcus Mueller <znek@mulle-kybernetik.com>
|
||||
|
||||
* sql: updated all generation scripts to the latest version (v0.9.15)
|
||||
|
||||
2004-12-09 Marcus Mueller <znek@mulle-kybernetik.com>
|
||||
|
||||
* v0.9.14
|
||||
|
||||
* appointment.ocs: added "ispublic", "isopaque", "status" and
|
||||
"orgmail".
|
||||
|
||||
* OCSiCalFieldExtractor.m: updated to extract new fields (see above)
|
||||
|
||||
* sql: updated generate-folderinfo-sql-for-users.sh
|
||||
|
||||
2004-10-19 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* OCSFolder.m: added new method -fetchContentsOfAllFiles method which
|
||||
fetches the contents of all files stored in the folder (required for
|
||||
iCal generation, such bulk fetches should be avoided if possible!)
|
||||
(v0.9.13)
|
||||
|
||||
2004-10-15 Marcus Mueller <znek@mulle-kybernetik.com>
|
||||
|
||||
* OCSStringFormatter.[hm]: minor cleanup (v0.9.12)
|
||||
|
||||
* v0.9.11
|
||||
|
||||
* OCSStringFormatter.[hm]: new class to format strings according to
|
||||
Database requirements (escaping etc.).
|
||||
|
||||
* OCSFolder.m: uses new OCSStringFormatter now.
|
||||
|
||||
2004-09-25 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* fixed compilation on MacOSX (v0.9.10)
|
||||
|
||||
2004-09-10 Helge Hess <helge.hess@skyrix.com>
|
||||
|
||||
* v0.9.9
|
||||
|
||||
* fixed some gcc warnings
|
||||
|
||||
* GNUmakefile.preamble: added pathes to compile against an FHS SOPE
|
||||
|
||||
* OCSiCalFieldExtractor.m: fixed type of sequence iCalEvent field
|
||||
|
||||
2004-09-01 Marcus Mueller <znek@mulle-kybernetik.com>
|
||||
|
||||
* GNUmakefile: install type models into $(GNUSTEP_USER_ROOT) (v0.9.8)
|
||||
|
||||
2004-08-27 Helge Hess <helge.hess@skyrix.com>
|
||||
|
||||
* v0.9.7
|
||||
|
||||
* OCSChannelManager.m: use PostgreSQL as adaptor, not PostgreSQL72
|
||||
|
||||
* OCSFolder.m: added support for doing folder sorting in SQL
|
||||
|
||||
2004-08-26 Helge Hess <helge.hess@skyrix.com>
|
||||
|
||||
* v0.9.6
|
||||
|
||||
* added OCSContactFieldExtractor
|
||||
|
||||
* sql: added sample contact folder create scripts
|
||||
|
||||
* OCSFolderType.m: read extractor class name from type model
|
||||
|
||||
* OCSFolderManager.m: added contact type model per default (v0.9.5)
|
||||
|
||||
2004-08-25 Helge Hess <helge.hess@skyrix.com>
|
||||
|
||||
* GNUmakefile: automatically install OCSTypeModels (v0.9.4)
|
||||
|
||||
2004-08-15 Helge Hess <helge.hess@skyrix.com>
|
||||
|
||||
* OCSFolder.m: added content deletion (v0.9.3)
|
||||
|
||||
* OCSFolder.m: added sanity check to store method (v0.9.2)
|
||||
|
||||
2004-08-14 Helge Hess <helge.hess@skyrix.com>
|
||||
|
||||
* v0.9.1
|
||||
|
||||
* OCSiCalFieldExtractor.m: extract new quick fields: location,
|
||||
partmails, sequence (does not yet handle allday and cycle due to
|
||||
NGiCal restrictions)
|
||||
|
||||
* appointment.ocs, sql/foldertablecreate-helge-privcal.psql,
|
||||
sql/testapt-agenor-helge-privcal.psql, sql/appointment-create.psql:
|
||||
added quick fields: isallday, iscycle, location, partmails, sequence
|
||||
|
||||
* started ocs_recreatequick tool intended for recreating a quick table
|
||||
based on the content table of a folder
|
||||
|
||||
2004-07-20 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* OCSChannelManager.m: fixed a bug in the channel GC which resulted
|
||||
in an exception during the GC NSTimer
|
||||
|
||||
2004-07-16 Helge Hess <helge.hess@skyrix.com>
|
||||
|
||||
* improved error handling in various files
|
||||
|
||||
2004-07-02 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* OCSChannelManager.m: added garbage collector for channel pools
|
||||
|
||||
2004-06-30 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* OCSChannelManager.m: implemented pooling
|
||||
|
||||
* OCSFolder.m: added quick fetches
|
||||
|
||||
* GNUmakefile.preamble: fix link path
|
||||
|
||||
* GNUmakefile (libOGoContentStore_HEADER_FILES_INSTALL_DIR): install
|
||||
headers in OGoContentStore
|
||||
|
||||
* GNUmakefile.preamble (ocs_ls_TOOL_LIBS): added static dependencies
|
||||
for OSX
|
||||
|
||||
2004-06-30 Marcus Mueller <znek@mulle-kybernetik.com>
|
||||
|
||||
* ocs_cat.m, ocs_ls.m, ocs_mkdir.m: fixed for gnustep compile.
|
||||
|
||||
2004-06-29 Helge Hess <helge.hess@opengroupware.org>
|
||||
|
||||
* created ChangeLog
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
# GNUstep makefile
|
||||
|
||||
-include ../config.make
|
||||
include $(GNUSTEP_MAKEFILES)/common.make
|
||||
include ./Version
|
||||
|
||||
LIBRARY_NAME = libOGoContentStore
|
||||
TOOL_NAME = test_quick_extract
|
||||
|
||||
TYPEMODELS_DIR = $(GNUSTEP_USER_ROOT)/Library/OCSTypeModels/
|
||||
|
||||
libOGoContentStore_HEADER_FILES_DIR = .
|
||||
libOGoContentStore_HEADER_FILES_INSTALL_DIR = /OGoContentStore
|
||||
# no headers, commented out: FHS_HEADER_DIRS = OGoContentStore
|
||||
|
||||
libOGoContentStore_OBJC_FILES += \
|
||||
iCalEntityObject+OCS.m \
|
||||
iCalRepeatableEntityObject+OCS.m \
|
||||
\
|
||||
OCSiCalFieldExtractor.m \
|
||||
OCSContactFieldExtractor.m \
|
||||
|
||||
libOGoContentStore_TYPEMODELS += \
|
||||
appointment.ocs \
|
||||
contact.ocs \
|
||||
|
||||
|
||||
test_quick_extract_OBJC_FILES += \
|
||||
test_quick_extract.m
|
||||
|
||||
-include GNUmakefile.preamble
|
||||
include $(GNUSTEP_MAKEFILES)/library.make
|
||||
include $(GNUSTEP_MAKEFILES)/tool.make
|
||||
-include GNUmakefile.postamble
|
||||
-include ../fhslib.make
|
||||
@@ -0,0 +1,15 @@
|
||||
# postprocessing
|
||||
|
||||
$(TYPEMODELS_DIR) :
|
||||
$(MKDIRS) $(TYPEMODELS_DIR)
|
||||
|
||||
ocs-typemodels : $(TYPEMODELS_DIR) $(libOGoContentStore_TYPEMODELS)
|
||||
@(if [ "$(libOGoContentStore_TYPEMODELS)" != "" ]; then \
|
||||
echo "Copying type models into install path ..."; \
|
||||
for ff in $(libOGoContentStore_TYPEMODELS); do \
|
||||
cp $$ff $(TYPEMODELS_DIR)/$$ff; \
|
||||
done; \
|
||||
fi)
|
||||
|
||||
after-install :: ocs-typemodels
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
# compilation settings
|
||||
|
||||
libOGoContentStore_LIBRARIES_DEPEND_UPON += \
|
||||
-lGDLContentStore \
|
||||
-lGDLAccess \
|
||||
-lNGiCal \
|
||||
-lNGExtensions \
|
||||
-lEOControl \
|
||||
-lSaxObjC
|
||||
|
||||
ADDITIONAL_INCLUDE_DIRS += -I. -I..
|
||||
|
||||
ADDITIONAL_LIB_DIRS += -L./$(GNUSTEP_OBJ_DIR)
|
||||
|
||||
SYSTEM_LIB_DIR += -L/usr/local/lib -L/usr/lib
|
||||
|
||||
ifeq ($(FOUNDATION_LIB),apple)
|
||||
libOGoContentStore_PREBIND_ADDR="0xC7700000"
|
||||
libOGoContentStore_LDFLAGS += -seg1addr $(libOGoContentStore_PREBIND_ADDR)
|
||||
endif
|
||||
|
||||
test_quick_extract_TOOL_LIBS += \
|
||||
-lEOControl \
|
||||
-lSaxObjC \
|
||||
-lDOM \
|
||||
-lNGExtensions \
|
||||
-lNGiCal \
|
||||
-lGDLContentStore \
|
||||
-lGDLAccess \
|
||||
-lOGoContentStore
|
||||
@@ -0,0 +1,128 @@
|
||||
/*
|
||||
Copyright (C) 2004-2005 SKYRIX Software AG
|
||||
|
||||
This file is part of OpenGroupware.org.
|
||||
|
||||
OGo is free software; you can redistribute it and/or modify it under
|
||||
the terms of the GNU Lesser General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
|
||||
OGo is distributed in the hope that it will be useful, but WITHOUT ANY
|
||||
WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
|
||||
License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with OGo; see the file COPYING. If not, write to the
|
||||
Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
|
||||
02111-1307, USA.
|
||||
*/
|
||||
|
||||
#include <GDLContentStore/GCSFieldExtractor.h>
|
||||
|
||||
@interface OCSContactFieldExtractor : GCSFieldExtractor
|
||||
@end
|
||||
|
||||
#include <NGiCal/NGVCard.h>
|
||||
#include "common.h"
|
||||
|
||||
@implementation OCSContactFieldExtractor
|
||||
|
||||
static NSString *fieldNames[] = {
|
||||
/* quickfield, vCard KVC path */
|
||||
@"givenName", @"n.given",
|
||||
@"cn", @"fn.stringValue",
|
||||
@"sn", @"n.family",
|
||||
@"l", @"preferredAdr.locality",
|
||||
@"mail", @"preferredEMail.stringValue",
|
||||
@"o", @"org.orgnam",
|
||||
@"ou", @"org.orgunit",
|
||||
@"telephoneNumber", @"preferredTel.stringValue",
|
||||
nil, nil
|
||||
};
|
||||
|
||||
- (NSMutableDictionary *)extractQuickFieldsFromVCard:(NGVCard *)_vCard {
|
||||
NSMutableDictionary *fields;
|
||||
unsigned i;
|
||||
|
||||
if (_vCard == nil)
|
||||
return nil;
|
||||
|
||||
fields = [NSMutableDictionary dictionaryWithCapacity:16];
|
||||
|
||||
for (i = 0; fieldNames[i] != nil; i += 2) {
|
||||
id value;
|
||||
|
||||
value = ([fieldNames[i + 1] length] > 0)
|
||||
? [_vCard valueForKeyPath:fieldNames[i + 1]]
|
||||
: nil;
|
||||
if (![value isNotNull]) value = [NSNull null];
|
||||
|
||||
[fields setObject:value forKey:[fieldNames[i] lowercaseString]];
|
||||
}
|
||||
return fields;
|
||||
}
|
||||
|
||||
- (NSMutableDictionary *)extractQuickFieldsFromVCardString:(NSString *)_str {
|
||||
NSArray *vCards;
|
||||
|
||||
if ((vCards = [NGVCard parseVCardsFromSource:_str]) == nil) {
|
||||
[self errorWithFormat:@"Could not parse content as a vCard."];
|
||||
return nil;
|
||||
}
|
||||
if ([vCards count] == 0) {
|
||||
[self errorWithFormat:@"Could not parse content as a vCard."];
|
||||
return nil;
|
||||
}
|
||||
|
||||
if ([vCards count] > 1)
|
||||
[self warnWithFormat:@"More than one vCard in content, using first."];
|
||||
|
||||
return [self extractQuickFieldsFromVCard:[vCards objectAtIndex:0]];
|
||||
}
|
||||
|
||||
- (NSMutableDictionary *)extractQuickFieldsFromContent:(NSString *)_content {
|
||||
NSMutableDictionary *fields;
|
||||
NSDictionary *plist;
|
||||
unsigned i;
|
||||
|
||||
if ([_content length] == 0)
|
||||
return nil;
|
||||
|
||||
if ([_content hasPrefix:@"BEGIN:VCARD"])
|
||||
return [self extractQuickFieldsFromVCardString:_content];
|
||||
|
||||
// TODO: we want to support vcard storage in the future?!
|
||||
|
||||
if ((plist = [_content propertyList]) == nil) {
|
||||
[self logWithFormat:@"ERROR: could not parse property list content!"];
|
||||
return nil;
|
||||
}
|
||||
|
||||
if (![plist isKindOfClass:[NSDictionary class]]) {
|
||||
[self logWithFormat:@"ERROR: parsed property list is not a dictionary!"];
|
||||
return nil;
|
||||
}
|
||||
|
||||
fields = [NSMutableDictionary dictionaryWithCapacity:16];
|
||||
|
||||
/* copy field values to quick record */
|
||||
for (i = 0; fieldNames[i] != nil; i += 2) {
|
||||
NSString *fieldName, *sqlName;
|
||||
id value;
|
||||
|
||||
fieldName = fieldNames[i];
|
||||
sqlName = [fieldName lowercaseString]; /* actually pgsql doesn't care */
|
||||
|
||||
value = [plist objectForKey:fieldName];
|
||||
if ([value isNotNull])
|
||||
[fields setObject:value forKey:sqlName];
|
||||
else
|
||||
[fields setObject:[NSNull null] forKey:sqlName];
|
||||
}
|
||||
|
||||
return fields;
|
||||
}
|
||||
|
||||
@end /* OCSContactFieldExtractor */
|
||||
@@ -0,0 +1,35 @@
|
||||
/*
|
||||
Copyright (C) 2004-2005 SKYRIX Software AG
|
||||
|
||||
This file is part of OpenGroupware.org.
|
||||
|
||||
OGo is free software; you can redistribute it and/or modify it under
|
||||
the terms of the GNU Lesser General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
|
||||
OGo is distributed in the hope that it will be useful, but WITHOUT ANY
|
||||
WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
|
||||
License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with OGo; see the file COPYING. If not, write to the
|
||||
Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
|
||||
02111-1307, USA.
|
||||
*/
|
||||
|
||||
#ifndef __OGoContentStore_OCSiCalFieldExtractor_H__
|
||||
#define __OGoContentStore_OCSiCalFieldExtractor_H__
|
||||
|
||||
#include <GDLContentStore/GCSFieldExtractor.h>
|
||||
|
||||
@interface OCSiCalFieldExtractor : GCSFieldExtractor
|
||||
{
|
||||
}
|
||||
|
||||
+ (id)sharedICalFieldExtractor;
|
||||
|
||||
@end
|
||||
|
||||
#endif /* __OGoContentStore_OCSiCalFieldExtractor_H__ */
|
||||
@@ -0,0 +1,251 @@
|
||||
/*
|
||||
Copyright (C) 2004 SKYRIX Software AG
|
||||
|
||||
This file is part of OpenGroupware.org.
|
||||
|
||||
OGo is free software; you can redistribute it and/or modify it under
|
||||
the terms of the GNU Lesser General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
|
||||
OGo is distributed in the hope that it will be useful, but WITHOUT ANY
|
||||
WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
|
||||
License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with OGo; see the file COPYING. If not, write to the
|
||||
Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
|
||||
02111-1307, USA.
|
||||
*/
|
||||
|
||||
#include "OCSiCalFieldExtractor.h"
|
||||
#include "common.h"
|
||||
#include <SaxObjC/SaxObjC.h>
|
||||
#include <NGiCal/NGiCal.h>
|
||||
#include "iCalEntityObject+OCS.h"
|
||||
#include "iCalRepeatableEntityObject+OCS.h"
|
||||
|
||||
@implementation OCSiCalFieldExtractor
|
||||
|
||||
static id<NSObject,SaxXMLReader> parser = nil;
|
||||
static SaxObjectDecoder *sax = nil;
|
||||
static OCSiCalFieldExtractor *extractor = nil;
|
||||
static NSCalendarDate *distantFuture = nil;
|
||||
static NSNumber *distantFutureNumber = nil;
|
||||
|
||||
+ (void)initialize {
|
||||
static BOOL didInit = NO;
|
||||
|
||||
if (didInit) return;
|
||||
didInit = YES;
|
||||
|
||||
parser = [[[SaxXMLReaderFactory standardXMLReaderFactory]
|
||||
createXMLReaderForMimeType:@"text/calendar"]
|
||||
retain];
|
||||
if (parser == nil)
|
||||
NSLog(@"ERROR: did not find a parser for text/calendar!");
|
||||
sax = [[SaxObjectDecoder alloc] initWithMappingNamed:@"NGiCal"];
|
||||
if (sax == nil)
|
||||
NSLog(@"ERROR: could not create the iCal SAX handler!");
|
||||
[parser setContentHandler:sax];
|
||||
[parser setErrorHandler:sax];
|
||||
|
||||
distantFuture = [[NSCalendarDate distantFuture] retain];
|
||||
/* INT_MAX due to Postgres constraint */
|
||||
distantFutureNumber = [[NSNumber numberWithUnsignedInt:INT_MAX] retain];
|
||||
}
|
||||
|
||||
+ (id)sharedICalFieldExtractor {
|
||||
if (extractor == nil) extractor = [[self alloc] init];
|
||||
return extractor;
|
||||
}
|
||||
|
||||
- (void)dealloc {
|
||||
[super dealloc];
|
||||
}
|
||||
|
||||
/* operations */
|
||||
|
||||
- (NSNumber *)numberForDate:(NSCalendarDate *)_date {
|
||||
if (_date == distantFuture)
|
||||
return distantFutureNumber;
|
||||
return [NSNumber numberWithUnsignedInt:[_date timeIntervalSince1970]];
|
||||
}
|
||||
|
||||
- (NSMutableDictionary *)extractQuickFieldsFromEvent:(iCalEvent *)_event {
|
||||
NSMutableDictionary *row;
|
||||
NSCalendarDate *startDate, *endDate;
|
||||
NSArray *attendees;
|
||||
NSString *uid, *title, *location, *status, *accessClass;
|
||||
NSNumber *sequence;
|
||||
id organizer;
|
||||
id participants, partmails;
|
||||
NSMutableString *partstates;
|
||||
unsigned i, count;
|
||||
|
||||
if (_event == nil)
|
||||
return nil;
|
||||
|
||||
/* extract values */
|
||||
|
||||
startDate = [_event startDate];
|
||||
endDate = [_event endDate];
|
||||
uid = [_event uid];
|
||||
title = [_event summary];
|
||||
location = [_event location];
|
||||
sequence = [_event sequence];
|
||||
accessClass = [[_event accessClass] uppercaseString];
|
||||
status = [[_event status] uppercaseString];
|
||||
|
||||
attendees = [_event attendees];
|
||||
partmails = [attendees valueForKey:@"rfc822Email"];
|
||||
partmails = [partmails componentsJoinedByString:@"\n"];
|
||||
participants = [attendees valueForKey:@"cn"];
|
||||
participants = [participants componentsJoinedByString:@"\n"];
|
||||
|
||||
/* build row */
|
||||
|
||||
row = [NSMutableDictionary dictionaryWithCapacity:8];
|
||||
|
||||
if ([uid isNotNull])
|
||||
[row setObject:uid forKey:@"uid"];
|
||||
else
|
||||
[self logWithFormat:@"WARNING: could not extract a uid from event!"];
|
||||
|
||||
[row setObject:[NSNumber numberWithBool:[_event isAllDay]]
|
||||
forKey:@"isallday"];
|
||||
[row setObject:[NSNumber numberWithBool:[_event isRecurrent]]
|
||||
forKey:@"iscycle"];
|
||||
[row setObject:[NSNumber numberWithBool:[_event isOpaque]]
|
||||
forKey:@"isopaque"];
|
||||
[row setObject:[NSNumber numberWithInt:[_event priorityNumber]]
|
||||
forKey:@"priority"];
|
||||
|
||||
if ([title isNotNull]) [row setObject:title forKey:@"title"];
|
||||
if ([location isNotNull]) [row setObject:location forKey:@"location"];
|
||||
if ([sequence isNotNull]) [row setObject:sequence forKey:@"sequence"];
|
||||
|
||||
if ([startDate isNotNull])
|
||||
[row setObject:[self numberForDate:startDate] forKey:@"startdate"];
|
||||
if ([endDate isNotNull])
|
||||
[row setObject:[self numberForDate:endDate] forKey:@"enddate"];
|
||||
|
||||
if ([_event isRecurrent]) {
|
||||
NSCalendarDate *date;
|
||||
|
||||
date = [_event lastPossibleRecurrenceStartDate];
|
||||
if (!date) {
|
||||
/* this could also be *nil*, but in the end it makes the fetchspecs
|
||||
more complex - thus we set it to a "reasonable" distant future */
|
||||
date = distantFuture;
|
||||
}
|
||||
[row setObject:[self numberForDate:date] forKey:@"cycleenddate"];
|
||||
[row setObject:[_event cycleInfo] forKey:@"cycleinfo"];
|
||||
}
|
||||
if ([participants length] > 0)
|
||||
[row setObject:participants forKey:@"participants"];
|
||||
if ([partmails length] > 0)
|
||||
[row setObject:partmails forKey:@"partmails"];
|
||||
|
||||
if ([status isNotNull]) {
|
||||
int code = 1;
|
||||
|
||||
if ([status isEqualToString:@"TENTATIVE"])
|
||||
code = 0;
|
||||
else if ([status isEqualToString:@"CANCELLED"])
|
||||
code = 2;
|
||||
[row setObject:[NSNumber numberWithInt:code] forKey:@"status"];
|
||||
}
|
||||
else {
|
||||
/* confirmed by default */
|
||||
[row setObject:[NSNumber numberWithInt:1] forKey:@"status"];
|
||||
}
|
||||
|
||||
if([accessClass isNotNull] && ![accessClass isEqualToString:@"PUBLIC"]) {
|
||||
[row setObject:[NSNumber numberWithBool:NO] forKey:@"ispublic"];
|
||||
}
|
||||
else {
|
||||
[row setObject:[NSNumber numberWithBool:YES] forKey:@"ispublic"];
|
||||
}
|
||||
|
||||
organizer = [_event organizer];
|
||||
if (organizer) {
|
||||
NSString *email;
|
||||
|
||||
email = [organizer valueForKey:@"rfc822Email"];
|
||||
if (email)
|
||||
[row setObject:email forKey:@"orgmail"];
|
||||
}
|
||||
|
||||
/* construct partstates */
|
||||
count = [attendees count];
|
||||
partstates = [[NSMutableString alloc] initWithCapacity:count * 2];
|
||||
for ( i = 0; i < count; i++) {
|
||||
iCalPerson *p;
|
||||
iCalPersonPartStat stat;
|
||||
|
||||
p = [attendees objectAtIndex:i];
|
||||
stat = [p participationStatus];
|
||||
if(i != 0)
|
||||
[partstates appendString:@"\n"];
|
||||
[partstates appendFormat:@"%d", stat];
|
||||
}
|
||||
[row setObject:partstates forKey:@"partstates"];
|
||||
[partstates release];
|
||||
return row;
|
||||
}
|
||||
|
||||
- (NSMutableDictionary *)extractQuickFieldsFromCalendar:(iCalCalendar *)_cal {
|
||||
NSArray *events;
|
||||
|
||||
if (_cal == nil)
|
||||
return nil;
|
||||
|
||||
events = [_cal events];
|
||||
if ([events count] == 0) {
|
||||
[self logWithFormat:@"ERROR: given calendar contains no events: %@", _cal];
|
||||
return nil;
|
||||
}
|
||||
if ([events count] > 1) {
|
||||
[self logWithFormat:
|
||||
@"WARNING: given calendar contains more than one event: %@",
|
||||
_cal];
|
||||
}
|
||||
|
||||
return [self extractQuickFieldsFromEvent:[events objectAtIndex:0]];
|
||||
}
|
||||
|
||||
- (NSMutableDictionary *)extractQuickFieldsFromContent:(NSString *)_content {
|
||||
NSAutoreleasePool *pool;
|
||||
NSDictionary *fields;
|
||||
id cal;
|
||||
|
||||
if (parser == nil || sax == nil)
|
||||
return nil;
|
||||
if ([_content length] == 0)
|
||||
return nil;
|
||||
|
||||
pool = [[NSAutoreleasePool alloc] init];
|
||||
|
||||
[parser parseFromSource:_content];
|
||||
cal = [sax rootObject];
|
||||
|
||||
fields = nil;
|
||||
if ([cal isKindOfClass:[iCalEvent class]])
|
||||
fields = [[self extractQuickFieldsFromEvent:cal] retain];
|
||||
else if ([cal isKindOfClass:[iCalCalendar class]])
|
||||
fields = [[self extractQuickFieldsFromCalendar:cal] retain];
|
||||
else if ([cal isNotNull]) {
|
||||
[self logWithFormat:@"ERROR: unexpected iCalendar parse result: %@",
|
||||
cal];
|
||||
}
|
||||
|
||||
[sax reset];
|
||||
|
||||
[pool release];
|
||||
|
||||
return [fields autorelease];
|
||||
}
|
||||
|
||||
@end /* OCSiCalFieldExtractor */
|
||||
@@ -0,0 +1,771 @@
|
||||
// !$*UTF8*$!
|
||||
{
|
||||
archiveVersion = 1;
|
||||
classes = {
|
||||
};
|
||||
objectVersion = 39;
|
||||
objects = {
|
||||
AD0CF943071FE16800E72147 = {
|
||||
children = (
|
||||
AD0CF976071FE18800E72147,
|
||||
AD0CF94F071FE18800E72147,
|
||||
AD0CF950071FE18800E72147,
|
||||
AD0CF94C071FE18800E72147,
|
||||
AD0CF984071FE18800E72147,
|
||||
AD0CF987071FE1B200E72147,
|
||||
AD0CF98D071FE1D400E72147,
|
||||
AD0CF977071FE18800E72147,
|
||||
AD0CF9B9071FE1FA00E72147,
|
||||
AD0CF990071FE1F000E72147,
|
||||
AD0CF98A071FE1C000E72147,
|
||||
AD0CF958071FE18800E72147,
|
||||
);
|
||||
isa = PBXGroup;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF945071FE16800E72147 = {
|
||||
buildSettings = {
|
||||
COPY_PHASE_STRIP = NO;
|
||||
};
|
||||
isa = PBXBuildStyle;
|
||||
name = Development;
|
||||
};
|
||||
AD0CF946071FE16800E72147 = {
|
||||
buildSettings = {
|
||||
COPY_PHASE_STRIP = YES;
|
||||
};
|
||||
isa = PBXBuildStyle;
|
||||
name = Deployment;
|
||||
};
|
||||
AD0CF947071FE16800E72147 = {
|
||||
buildSettings = {
|
||||
};
|
||||
buildStyles = (
|
||||
AD0CF945071FE16800E72147,
|
||||
AD0CF946071FE16800E72147,
|
||||
);
|
||||
hasScannedForEncodings = 0;
|
||||
isa = PBXProject;
|
||||
mainGroup = AD0CF943071FE16800E72147;
|
||||
projectDirPath = "";
|
||||
targets = (
|
||||
);
|
||||
};
|
||||
AD0CF94B071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = appointment.ocs;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF94C071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = ChangeLog;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
usesTabs = 1;
|
||||
};
|
||||
AD0CF94D071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.h;
|
||||
path = common.h;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF94E071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = contact.ocs;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF94F071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = COPYING;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF950071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = COPYRIGHT;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF951071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.h;
|
||||
path = "EOAdaptorChannel+OCS.h";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF952071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = "EOAdaptorChannel+OCS.m";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF953071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.h;
|
||||
path = "EOQualifier+OCS.h";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF954071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = "EOQualifier+OCS.m";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF955071FE18800E72147 = {
|
||||
explicitFileType = sourcecode.make;
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
path = GNUmakefile;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
};
|
||||
AD0CF956071FE18800E72147 = {
|
||||
explicitFileType = sourcecode.make;
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
path = GNUmakefile.postamble;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
};
|
||||
AD0CF957071FE18800E72147 = {
|
||||
explicitFileType = sourcecode.make;
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
path = GNUmakefile.preamble;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
};
|
||||
AD0CF958071FE18800E72147 = {
|
||||
children = (
|
||||
AD0CF959071FE18800E72147,
|
||||
AD0CF95A071FE18800E72147,
|
||||
AD0CF95B071FE18800E72147,
|
||||
);
|
||||
isa = PBXGroup;
|
||||
path = misc;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF959071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = icaltest.ical;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF95A071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = iNetOrgPerson.txt;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF95B071FE18800E72147 = {
|
||||
children = (
|
||||
AD0CF95C071FE18800E72147,
|
||||
AD0CF95D071FE18800E72147,
|
||||
AD0CF95E071FE18800E72147,
|
||||
);
|
||||
isa = PBXGroup;
|
||||
path = test1;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF95C071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.h;
|
||||
path = common.h;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF95D071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = GNUmakefile;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF95E071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = test1.m;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF95F071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.h;
|
||||
path = "NSURL+OCS.h";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF960071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = "NSURL+OCS.m";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF961071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = ocs_cat.m;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF962071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = ocs_ls.m;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF963071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = ocs_mkdir.m;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF964071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = ocs_recreatequick.m;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF965071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.h;
|
||||
path = OCSChannelManager.h;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF966071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = OCSChannelManager.m;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF967071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = OCSContactFieldExtractor.m;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF968071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.h;
|
||||
path = OCSContext.h;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF969071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = OCSContext.m;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF96A071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.h;
|
||||
path = OCSFieldExtractor.h;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF96B071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = OCSFieldExtractor.m;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF96C071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.h;
|
||||
path = OCSFieldInfo.h;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF96D071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = OCSFieldInfo.m;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF96E071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.h;
|
||||
path = OCSFolder.h;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF96F071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = OCSFolder.m;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF970071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.h;
|
||||
path = OCSFolderManager.h;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF971071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = OCSFolderManager.m;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF972071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.h;
|
||||
path = OCSFolderType.h;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF973071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = OCSFolderType.m;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF974071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.h;
|
||||
path = OCSiCalFieldExtractor.h;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF975071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = OCSiCalFieldExtractor.m;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF976071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = README;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF977071FE18800E72147 = {
|
||||
children = (
|
||||
AD0CF97E071FE18800E72147,
|
||||
ADB79C3707D4B7AA00CA782A,
|
||||
ADB79C3A07D4B7B800CA782A,
|
||||
);
|
||||
isa = PBXGroup;
|
||||
name = SQL;
|
||||
path = sql;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF978071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = "appointment-create.psql";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
usesTabs = 1;
|
||||
};
|
||||
AD0CF979071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = "folderinfo-create.psql";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
usesTabs = 1;
|
||||
};
|
||||
AD0CF97A071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = "foldertablecreate-helge-privcal.psql";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
usesTabs = 1;
|
||||
};
|
||||
AD0CF97B071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = "foldertablecreate-root.psql";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
usesTabs = 1;
|
||||
};
|
||||
AD0CF97C071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = "foldertablecreate-test-contacts.psql";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
usesTabs = 1;
|
||||
};
|
||||
AD0CF97D071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text.script.sh;
|
||||
path = "generate-folderinfo-sql-for-users.sh";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
usesTabs = 1;
|
||||
};
|
||||
AD0CF97E071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = README;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF97F071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = "register-agenor-helge-privcal.psql";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
usesTabs = 1;
|
||||
};
|
||||
AD0CF980071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = "register-agenor-test-contacts.psql";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
usesTabs = 1;
|
||||
};
|
||||
AD0CF981071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = "testapt-agenor-helge-privcal.psql";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
usesTabs = 1;
|
||||
};
|
||||
AD0CF982071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = "testapt-hh.psql";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
usesTabs = 1;
|
||||
};
|
||||
AD0CF983071FE18800E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = "testcontact-agenor-test-contact.psql";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
usesTabs = 1;
|
||||
};
|
||||
AD0CF984071FE18800E72147 = {
|
||||
explicitFileType = sourcecode.make;
|
||||
fileEncoding = 5;
|
||||
indentWidth = 8;
|
||||
isa = PBXFileReference;
|
||||
path = Version;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
tabWidth = 8;
|
||||
};
|
||||
AD0CF987071FE1B200E72147 = {
|
||||
children = (
|
||||
AD0CF955071FE18800E72147,
|
||||
AD0CF957071FE18800E72147,
|
||||
AD0CF956071FE18800E72147,
|
||||
);
|
||||
isa = PBXGroup;
|
||||
name = Makefiles;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF98A071FE1C000E72147 = {
|
||||
children = (
|
||||
AD0CF961071FE18800E72147,
|
||||
AD0CF962071FE18800E72147,
|
||||
AD0CF963071FE18800E72147,
|
||||
AD0CF964071FE18800E72147,
|
||||
);
|
||||
isa = PBXGroup;
|
||||
name = Tools;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF98D071FE1D400E72147 = {
|
||||
children = (
|
||||
AD0CF94E071FE18800E72147,
|
||||
AD0CF94B071FE18800E72147,
|
||||
);
|
||||
isa = PBXGroup;
|
||||
name = Mappings;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF990071FE1F000E72147 = {
|
||||
children = (
|
||||
AD0CF94D071FE18800E72147,
|
||||
AD0CF966071FE18800E72147,
|
||||
AD0CF967071FE18800E72147,
|
||||
AD0CF969071FE18800E72147,
|
||||
AD0CF96B071FE18800E72147,
|
||||
AD0CF96D071FE18800E72147,
|
||||
AD0CF96F071FE18800E72147,
|
||||
AD0CF971071FE18800E72147,
|
||||
AD0CF973071FE18800E72147,
|
||||
AD0CF975071FE18800E72147,
|
||||
AD0CF9CD071FE4A400E72147,
|
||||
AD0CF960071FE18800E72147,
|
||||
AD0CF952071FE18800E72147,
|
||||
AD0CF954071FE18800E72147,
|
||||
ADB79C6A07D4B92B00CA782A,
|
||||
);
|
||||
indentWidth = 2;
|
||||
isa = PBXGroup;
|
||||
name = Classes;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF9B9071FE1FA00E72147 = {
|
||||
children = (
|
||||
AD0CF965071FE18800E72147,
|
||||
AD0CF968071FE18800E72147,
|
||||
AD0CF96A071FE18800E72147,
|
||||
AD0CF96C071FE18800E72147,
|
||||
AD0CF96E071FE18800E72147,
|
||||
AD0CF970071FE18800E72147,
|
||||
AD0CF972071FE18800E72147,
|
||||
AD0CF974071FE18800E72147,
|
||||
AD0CF9CC071FE4A400E72147,
|
||||
AD0CF95F071FE18800E72147,
|
||||
AD0CF951071FE18800E72147,
|
||||
AD0CF953071FE18800E72147,
|
||||
ADB79C6907D4B92B00CA782A,
|
||||
);
|
||||
indentWidth = 2;
|
||||
isa = PBXGroup;
|
||||
name = Headers;
|
||||
path = "";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF9CC071FE4A400E72147 = {
|
||||
fileEncoding = 4;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.h;
|
||||
path = OCSStringFormatter.h;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF9CD071FE4A400E72147 = {
|
||||
fileEncoding = 5;
|
||||
indentWidth = 2;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = OCSStringFormatter.m;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
ADB79C3207D4B7A200CA782A = {
|
||||
fileEncoding = 5;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = "folderinfo-create.sqlite";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
ADB79C3307D4B7A200CA782A = {
|
||||
fileEncoding = 5;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text;
|
||||
path = "foldertablecreate-helge-privcal.sqlite";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
ADB79C3407D4B7A200CA782A = {
|
||||
fileEncoding = 5;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = text.script.sh;
|
||||
path = "generate-folderinfo-sql-for-users-sqlite.sh";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
ADB79C3707D4B7AA00CA782A = {
|
||||
children = (
|
||||
ADB79C3207D4B7A200CA782A,
|
||||
ADB79C3307D4B7A200CA782A,
|
||||
ADB79C3407D4B7A200CA782A,
|
||||
);
|
||||
isa = PBXGroup;
|
||||
name = SQLite;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
ADB79C3A07D4B7B800CA782A = {
|
||||
children = (
|
||||
AD0CF97D071FE18800E72147,
|
||||
AD0CF978071FE18800E72147,
|
||||
AD0CF979071FE18800E72147,
|
||||
AD0CF97A071FE18800E72147,
|
||||
AD0CF97B071FE18800E72147,
|
||||
AD0CF97C071FE18800E72147,
|
||||
AD0CF97F071FE18800E72147,
|
||||
AD0CF980071FE18800E72147,
|
||||
AD0CF981071FE18800E72147,
|
||||
AD0CF982071FE18800E72147,
|
||||
AD0CF983071FE18800E72147,
|
||||
);
|
||||
isa = PBXGroup;
|
||||
name = PostgreSQL;
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
ADB79C6907D4B92B00CA782A = {
|
||||
fileEncoding = 4;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.h;
|
||||
path = "iCalRepeatableEntityObject+OCS.h";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
ADB79C6A07D4B92B00CA782A = {
|
||||
fileEncoding = 4;
|
||||
isa = PBXFileReference;
|
||||
lastKnownFileType = sourcecode.c.objc;
|
||||
path = "iCalRepeatableEntityObject+OCS.m";
|
||||
refType = 4;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
};
|
||||
rootObject = AD0CF947071FE16800E72147;
|
||||
}
|
||||
@@ -0,0 +1,242 @@
|
||||
// !$*UTF8*$!
|
||||
{
|
||||
archiveVersion = 1;
|
||||
classes = {
|
||||
};
|
||||
objectVersion = 42;
|
||||
objects = {
|
||||
|
||||
/* Begin PBXBuildStyle section */
|
||||
AD0CF945071FE16800E72147 /* Development */ = {
|
||||
isa = PBXBuildStyle;
|
||||
buildSettings = {
|
||||
COPY_PHASE_STRIP = NO;
|
||||
};
|
||||
name = Development;
|
||||
};
|
||||
AD0CF946071FE16800E72147 /* Deployment */ = {
|
||||
isa = PBXBuildStyle;
|
||||
buildSettings = {
|
||||
COPY_PHASE_STRIP = YES;
|
||||
};
|
||||
name = Deployment;
|
||||
};
|
||||
/* End PBXBuildStyle section */
|
||||
|
||||
/* Begin PBXFileReference section */
|
||||
AD0CF94B071FE18800E72147 /* appointment.ocs */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = appointment.ocs; sourceTree = "<group>"; };
|
||||
AD0CF94C071FE18800E72147 /* ChangeLog */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 8; lastKnownFileType = text; path = ChangeLog; sourceTree = "<group>"; tabWidth = 8; usesTabs = 1; };
|
||||
AD0CF94D071FE18800E72147 /* common.h */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 2; lastKnownFileType = sourcecode.c.h; path = common.h; sourceTree = "<group>"; };
|
||||
AD0CF94E071FE18800E72147 /* contact.ocs */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = contact.ocs; sourceTree = "<group>"; };
|
||||
AD0CF94F071FE18800E72147 /* COPYING */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = COPYING; sourceTree = "<group>"; };
|
||||
AD0CF950071FE18800E72147 /* COPYRIGHT */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = COPYRIGHT; sourceTree = "<group>"; };
|
||||
AD0CF955071FE18800E72147 /* GNUmakefile */ = {isa = PBXFileReference; explicitFileType = sourcecode.make; fileEncoding = 5; indentWidth = 8; path = GNUmakefile; sourceTree = "<group>"; tabWidth = 8; };
|
||||
AD0CF956071FE18800E72147 /* GNUmakefile.postamble */ = {isa = PBXFileReference; explicitFileType = sourcecode.make; fileEncoding = 5; indentWidth = 8; path = GNUmakefile.postamble; sourceTree = "<group>"; tabWidth = 8; };
|
||||
AD0CF957071FE18800E72147 /* GNUmakefile.preamble */ = {isa = PBXFileReference; explicitFileType = sourcecode.make; fileEncoding = 5; indentWidth = 8; path = GNUmakefile.preamble; sourceTree = "<group>"; tabWidth = 8; };
|
||||
AD0CF959071FE18800E72147 /* icaltest.ical */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = icaltest.ical; sourceTree = "<group>"; };
|
||||
AD0CF95A071FE18800E72147 /* iNetOrgPerson.txt */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = iNetOrgPerson.txt; sourceTree = "<group>"; };
|
||||
AD0CF95C071FE18800E72147 /* common.h */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.h; path = common.h; sourceTree = "<group>"; };
|
||||
AD0CF95D071FE18800E72147 /* GNUmakefile */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = GNUmakefile; sourceTree = "<group>"; };
|
||||
AD0CF95E071FE18800E72147 /* test1.m */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.objc; path = test1.m; sourceTree = "<group>"; };
|
||||
AD0CF967071FE18800E72147 /* OCSContactFieldExtractor.m */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 2; lastKnownFileType = sourcecode.c.objc; path = OCSContactFieldExtractor.m; sourceTree = "<group>"; };
|
||||
AD0CF974071FE18800E72147 /* OCSiCalFieldExtractor.h */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 2; lastKnownFileType = sourcecode.c.h; path = OCSiCalFieldExtractor.h; sourceTree = "<group>"; };
|
||||
AD0CF975071FE18800E72147 /* OCSiCalFieldExtractor.m */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 2; lastKnownFileType = sourcecode.c.objc; path = OCSiCalFieldExtractor.m; sourceTree = "<group>"; };
|
||||
AD0CF976071FE18800E72147 /* README */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = README; sourceTree = "<group>"; };
|
||||
AD0CF978071FE18800E72147 /* appointment-create.psql */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 8; lastKnownFileType = text; path = "appointment-create.psql"; sourceTree = "<group>"; tabWidth = 8; usesTabs = 1; };
|
||||
AD0CF979071FE18800E72147 /* folderinfo-create.psql */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 8; lastKnownFileType = text; path = "folderinfo-create.psql"; sourceTree = "<group>"; tabWidth = 8; usesTabs = 1; };
|
||||
AD0CF97A071FE18800E72147 /* foldertablecreate-helge-privcal.psql */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 8; lastKnownFileType = text; path = "foldertablecreate-helge-privcal.psql"; sourceTree = "<group>"; tabWidth = 8; usesTabs = 1; };
|
||||
AD0CF97B071FE18800E72147 /* foldertablecreate-root.psql */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 8; lastKnownFileType = text; path = "foldertablecreate-root.psql"; sourceTree = "<group>"; tabWidth = 8; usesTabs = 1; };
|
||||
AD0CF97C071FE18800E72147 /* foldertablecreate-test-contacts.psql */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 8; lastKnownFileType = text; path = "foldertablecreate-test-contacts.psql"; sourceTree = "<group>"; tabWidth = 8; usesTabs = 1; };
|
||||
AD0CF97D071FE18800E72147 /* generate-folderinfo-sql-for-users.sh */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 8; lastKnownFileType = text.script.sh; path = "generate-folderinfo-sql-for-users.sh"; sourceTree = "<group>"; tabWidth = 8; usesTabs = 1; };
|
||||
AD0CF97E071FE18800E72147 /* README */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = README; sourceTree = "<group>"; };
|
||||
AD0CF97F071FE18800E72147 /* register-agenor-helge-privcal.psql */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 8; lastKnownFileType = text; path = "register-agenor-helge-privcal.psql"; sourceTree = "<group>"; tabWidth = 8; usesTabs = 1; };
|
||||
AD0CF980071FE18800E72147 /* register-agenor-test-contacts.psql */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 8; lastKnownFileType = text; path = "register-agenor-test-contacts.psql"; sourceTree = "<group>"; tabWidth = 8; usesTabs = 1; };
|
||||
AD0CF981071FE18800E72147 /* testapt-agenor-helge-privcal.psql */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 8; lastKnownFileType = text; path = "testapt-agenor-helge-privcal.psql"; sourceTree = "<group>"; tabWidth = 8; usesTabs = 1; };
|
||||
AD0CF982071FE18800E72147 /* testapt-hh.psql */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 8; lastKnownFileType = text; path = "testapt-hh.psql"; sourceTree = "<group>"; tabWidth = 8; usesTabs = 1; };
|
||||
AD0CF983071FE18800E72147 /* testcontact-agenor-test-contact.psql */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 8; lastKnownFileType = text; path = "testcontact-agenor-test-contact.psql"; sourceTree = "<group>"; tabWidth = 8; usesTabs = 1; };
|
||||
AD0CF984071FE18800E72147 /* Version */ = {isa = PBXFileReference; explicitFileType = sourcecode.make; fileEncoding = 5; indentWidth = 8; path = Version; sourceTree = "<group>"; tabWidth = 8; };
|
||||
AD3D69BE0879884F005FA0C4 /* iCalEntityObject+OCS.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "iCalEntityObject+OCS.h"; sourceTree = "<group>"; };
|
||||
AD3D69BF0879884F005FA0C4 /* iCalEntityObject+OCS.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "iCalEntityObject+OCS.m"; sourceTree = "<group>"; };
|
||||
ADB79C3207D4B7A200CA782A /* folderinfo-create.sqlite */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = "folderinfo-create.sqlite"; sourceTree = "<group>"; };
|
||||
ADB79C3307D4B7A200CA782A /* foldertablecreate-helge-privcal.sqlite */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = "foldertablecreate-helge-privcal.sqlite"; sourceTree = "<group>"; };
|
||||
ADB79C3407D4B7A200CA782A /* generate-folderinfo-sql-for-users-sqlite.sh */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text.script.sh; path = "generate-folderinfo-sql-for-users-sqlite.sh"; sourceTree = "<group>"; };
|
||||
ADB79C6907D4B92B00CA782A /* iCalRepeatableEntityObject+OCS.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "iCalRepeatableEntityObject+OCS.h"; sourceTree = "<group>"; };
|
||||
ADB79C6A07D4B92B00CA782A /* iCalRepeatableEntityObject+OCS.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "iCalRepeatableEntityObject+OCS.m"; sourceTree = "<group>"; };
|
||||
/* End PBXFileReference section */
|
||||
|
||||
/* Begin PBXGroup section */
|
||||
AD0CF943071FE16800E72147 = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
AD0CF976071FE18800E72147 /* README */,
|
||||
AD0CF94F071FE18800E72147 /* COPYING */,
|
||||
AD0CF950071FE18800E72147 /* COPYRIGHT */,
|
||||
AD0CF94C071FE18800E72147 /* ChangeLog */,
|
||||
AD0CF984071FE18800E72147 /* Version */,
|
||||
AD0CF987071FE1B200E72147 /* Makefiles */,
|
||||
AD0CF98D071FE1D400E72147 /* Mappings */,
|
||||
AD0CF977071FE18800E72147 /* SQL */,
|
||||
AD0CF9B9071FE1FA00E72147 /* Headers */,
|
||||
AD0CF990071FE1F000E72147 /* Classes */,
|
||||
AD0CF958071FE18800E72147 /* misc */,
|
||||
);
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF958071FE18800E72147 /* misc */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
AD0CF959071FE18800E72147 /* icaltest.ical */,
|
||||
AD0CF95A071FE18800E72147 /* iNetOrgPerson.txt */,
|
||||
AD0CF95B071FE18800E72147 /* test1 */,
|
||||
);
|
||||
path = misc;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF95B071FE18800E72147 /* test1 */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
AD0CF95C071FE18800E72147 /* common.h */,
|
||||
AD0CF95D071FE18800E72147 /* GNUmakefile */,
|
||||
AD0CF95E071FE18800E72147 /* test1.m */,
|
||||
);
|
||||
path = test1;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF977071FE18800E72147 /* SQL */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
AD0CF97E071FE18800E72147 /* README */,
|
||||
ADB79C3707D4B7AA00CA782A /* SQLite */,
|
||||
ADB79C3A07D4B7B800CA782A /* PostgreSQL */,
|
||||
);
|
||||
name = SQL;
|
||||
path = sql;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF987071FE1B200E72147 /* Makefiles */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
AD0CF955071FE18800E72147 /* GNUmakefile */,
|
||||
AD0CF957071FE18800E72147 /* GNUmakefile.preamble */,
|
||||
AD0CF956071FE18800E72147 /* GNUmakefile.postamble */,
|
||||
);
|
||||
name = Makefiles;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF98D071FE1D400E72147 /* Mappings */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
AD0CF94E071FE18800E72147 /* contact.ocs */,
|
||||
AD0CF94B071FE18800E72147 /* appointment.ocs */,
|
||||
);
|
||||
name = Mappings;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF990071FE1F000E72147 /* Classes */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
AD0CF94D071FE18800E72147 /* common.h */,
|
||||
AD0CF967071FE18800E72147 /* OCSContactFieldExtractor.m */,
|
||||
AD0CF975071FE18800E72147 /* OCSiCalFieldExtractor.m */,
|
||||
AD3D69BF0879884F005FA0C4 /* iCalEntityObject+OCS.m */,
|
||||
ADB79C6A07D4B92B00CA782A /* iCalRepeatableEntityObject+OCS.m */,
|
||||
);
|
||||
indentWidth = 2;
|
||||
name = Classes;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
AD0CF9B9071FE1FA00E72147 /* Headers */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
AD0CF974071FE18800E72147 /* OCSiCalFieldExtractor.h */,
|
||||
AD3D69BE0879884F005FA0C4 /* iCalEntityObject+OCS.h */,
|
||||
ADB79C6907D4B92B00CA782A /* iCalRepeatableEntityObject+OCS.h */,
|
||||
);
|
||||
indentWidth = 2;
|
||||
name = Headers;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
ADB79C3707D4B7AA00CA782A /* SQLite */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
ADB79C3207D4B7A200CA782A /* folderinfo-create.sqlite */,
|
||||
ADB79C3307D4B7A200CA782A /* foldertablecreate-helge-privcal.sqlite */,
|
||||
ADB79C3407D4B7A200CA782A /* generate-folderinfo-sql-for-users-sqlite.sh */,
|
||||
);
|
||||
name = SQLite;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
ADB79C3A07D4B7B800CA782A /* PostgreSQL */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
AD0CF97D071FE18800E72147 /* generate-folderinfo-sql-for-users.sh */,
|
||||
AD0CF978071FE18800E72147 /* appointment-create.psql */,
|
||||
AD0CF979071FE18800E72147 /* folderinfo-create.psql */,
|
||||
AD0CF97A071FE18800E72147 /* foldertablecreate-helge-privcal.psql */,
|
||||
AD0CF97B071FE18800E72147 /* foldertablecreate-root.psql */,
|
||||
AD0CF97C071FE18800E72147 /* foldertablecreate-test-contacts.psql */,
|
||||
AD0CF97F071FE18800E72147 /* register-agenor-helge-privcal.psql */,
|
||||
AD0CF980071FE18800E72147 /* register-agenor-test-contacts.psql */,
|
||||
AD0CF981071FE18800E72147 /* testapt-agenor-helge-privcal.psql */,
|
||||
AD0CF982071FE18800E72147 /* testapt-hh.psql */,
|
||||
AD0CF983071FE18800E72147 /* testcontact-agenor-test-contact.psql */,
|
||||
);
|
||||
name = PostgreSQL;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
/* End PBXGroup section */
|
||||
|
||||
/* Begin PBXProject section */
|
||||
AD0CF947071FE16800E72147 /* Project object */ = {
|
||||
isa = PBXProject;
|
||||
buildConfigurationList = AD3D68B4087954A2005FA0C4 /* Build configuration list for PBXProject "OGoContentStore" */;
|
||||
buildSettings = {
|
||||
};
|
||||
buildStyles = (
|
||||
AD0CF945071FE16800E72147 /* Development */,
|
||||
AD0CF946071FE16800E72147 /* Deployment */,
|
||||
);
|
||||
hasScannedForEncodings = 0;
|
||||
mainGroup = AD0CF943071FE16800E72147;
|
||||
projectDirPath = "";
|
||||
targets = (
|
||||
);
|
||||
};
|
||||
/* End PBXProject section */
|
||||
|
||||
/* Begin XCBuildConfiguration section */
|
||||
AD3D68B5087954A2005FA0C4 /* Development */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
};
|
||||
name = Development;
|
||||
};
|
||||
AD3D68B6087954A2005FA0C4 /* Deployment */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
};
|
||||
name = Deployment;
|
||||
};
|
||||
AD3D68B7087954A2005FA0C4 /* Default */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
};
|
||||
name = Default;
|
||||
};
|
||||
/* End XCBuildConfiguration section */
|
||||
|
||||
/* Begin XCConfigurationList section */
|
||||
AD3D68B4087954A2005FA0C4 /* Build configuration list for PBXProject "OGoContentStore" */ = {
|
||||
isa = XCConfigurationList;
|
||||
buildConfigurations = (
|
||||
AD3D68B5087954A2005FA0C4 /* Development */,
|
||||
AD3D68B6087954A2005FA0C4 /* Deployment */,
|
||||
AD3D68B7087954A2005FA0C4 /* Default */,
|
||||
);
|
||||
defaultConfigurationIsVisible = 0;
|
||||
defaultConfigurationName = Default;
|
||||
};
|
||||
/* End XCConfigurationList section */
|
||||
};
|
||||
rootObject = AD0CF947071FE16800E72147 /* Project object */;
|
||||
}
|
||||
@@ -0,0 +1,144 @@
|
||||
Storage Backend
|
||||
===============
|
||||
|
||||
The storage backend implements the "low level" folder abstraction, which is
|
||||
basically an arbitary "BLOB" containing some document. The feature is that
|
||||
we extract "quick access" / "searchable" attributes from the document content.
|
||||
|
||||
Further it contains the "folder management" API, as named folders can be stored
|
||||
in different databases.
|
||||
Note: we need a way to tell where "new" folders should be created
|
||||
Note: to sync with LDAP we need to periodically delete or archive old folders
|
||||
|
||||
Folders have associated a type (like 'calendar') which defines the query
|
||||
attributes and serialization format.
|
||||
|
||||
TODO
|
||||
====
|
||||
- hierarchies deeper than 4 (properly filter on path in OCS)
|
||||
|
||||
Open Questions
|
||||
==============
|
||||
|
||||
System-meta-data in the blob-table or in the quick-table?
|
||||
- master data belongs into the blob table
|
||||
- could be regular 'NSxxx' keys to differentiate meta data from
|
||||
|
||||
Class Hierarchy
|
||||
===============
|
||||
|
||||
[NSObject]
|
||||
OCSContext - tracking context
|
||||
OCSFolder - represents a single folder
|
||||
OCSFolderManager - manages folders
|
||||
OCSFolderType - the mapping info for a specific folder-type
|
||||
OCSFieldInfo - mapping info for one 'quick field'
|
||||
OCSChannelManager - maintains EOAdaptorChannel objects
|
||||
|
||||
TBD:
|
||||
- field 'extractor'
|
||||
- field 'value' (eg array values for participants?)
|
||||
- BLOB archiver/unarchiver
|
||||
|
||||
Defaults
|
||||
========
|
||||
|
||||
OCSFolderInfoURL - the DB URL where the folder-info table is located
|
||||
eg: http://OGo:OGo@localhost/test/folder_info
|
||||
|
||||
OCSFolderManagerDebugEnabled - enable folder-manager debug logs
|
||||
OCSFolderManagerSQLDebugEnabled - enable folder-manager SQL gen debug logs
|
||||
|
||||
OCSChannelManagerDebugEnabled - enable channel debug pooling logs
|
||||
OCSChannelManagerPoolDebugEnabled - debug pool handle allocation
|
||||
|
||||
OCSChannelExpireAge - if that age in seconds is exceeded, a channel
|
||||
will be removed from the pool
|
||||
OCSChannelCollectionTimer - time in seconds. each n-seconds the pool will be
|
||||
checked for channels too old
|
||||
|
||||
[PGDebugEnabled] - enable PostgreSQL adaptor debugging
|
||||
|
||||
URLs
|
||||
====
|
||||
|
||||
"Database URLs"
|
||||
|
||||
We use the schema:
|
||||
postgresql://[user]:[password]@[host]:[port]/[dbname]/[tablename]
|
||||
|
||||
BLOB Formats
|
||||
============
|
||||
|
||||
- TBD
|
||||
- iCal, XML
|
||||
- problem with iCal is that a complete and valid iCal file is different from
|
||||
just the vevent. so we basically need to parse those files in any case.
|
||||
- XML: the iCal SaxDriver reports XML events, so we can easily store that as
|
||||
XML
|
||||
- we need to parse the BLOB for different clients anyway (iCal != iCal ...)
|
||||
- XML: we could use some XML query extension to PG in the future?
|
||||
|
||||
Update: we now have OCSiCalFieldExtractor
|
||||
- it parses the BLOB as an iCalendar file and extracts a set of fixed
|
||||
keys:
|
||||
- title - plain copy of "summary"
|
||||
- uid - plain copy
|
||||
- startdate - date as utime
|
||||
- enddate - date as utime
|
||||
- participants - CNs of attendees separated by comma ", "
|
||||
- location
|
||||
- partmails
|
||||
- sequence
|
||||
- TBD: iscyclic
|
||||
- TBD: isallday
|
||||
- TBD: cycles - I guess the client should fetch the BLOB to resolve
|
||||
- the field extractor is accessed by OCSFolder using the folderinfo:
|
||||
extractor = [self->folderInfo quickExtractor];
|
||||
quickRow = [extractor extractQuickFieldsFromContent:_content];
|
||||
|
||||
Support Tools
|
||||
=============
|
||||
|
||||
- tools we need:
|
||||
- one to recreate a quick table based on the blob table
|
||||
|
||||
Notes
|
||||
=====
|
||||
|
||||
- need to use http:// URLs for connect info, until generic URLs in
|
||||
libFoundation are fixed (the parses breaks on the login/password parts)
|
||||
|
||||
QA
|
||||
==
|
||||
|
||||
Q: Why do we use two tables, we could store the quick columns in the blob?
|
||||
==
|
||||
They could be in the same table. I considered using separate tables since the
|
||||
quick table is likely to be recreated now and then if BLOB indexing
|
||||
requirements change.
|
||||
Actually one could even use different _quick tables which share a common BLOB
|
||||
table.
|
||||
(a quick table is nothing more than a database index and like with DB indexes
|
||||
multiple ones for different requirements can make sense).
|
||||
|
||||
Further it might improve caching behaviour for row based caches (the quick
|
||||
table is going to be queried much more often) - not sure whether this is
|
||||
relevant with PostgreSQL, probably not?
|
||||
|
||||
Q: Can we use a VARCHAR primary key?
|
||||
==
|
||||
I asked in the postgres IRC channel and apparently the performance penalty of
|
||||
string primary keys isn't big.
|
||||
We could also use an 'internal' int sequence in addition (might be useful for
|
||||
supporting ZideLook)
|
||||
Motivation: the 'iCalendar' ID is a string and usually looks like a GUID.
|
||||
|
||||
Q: Why using VARCHAR instead of TEXT in the BLOB?
|
||||
==
|
||||
To quote PostgreSQL documentation:
|
||||
"There are no performance differences between these three types, apart from
|
||||
the increased storage size when using the blank-padded type."
|
||||
So varchar(xx) is just a large TEXT. Since we intend to store mostly small
|
||||
snippets of data (tiny XML fragments), I considered VARCHAR the more
|
||||
appropriate type.
|
||||
@@ -0,0 +1,14 @@
|
||||
# Version file
|
||||
|
||||
MAJOR_VERSION=0
|
||||
MINOR_VERSION=9
|
||||
SUBMINOR_VERSION:=33
|
||||
|
||||
# v0.9.30 requires libNGiCal v4.5.48
|
||||
# v0.9.26 requires libGDLContentStore v4.5.26
|
||||
# v0.9.19 requires libNGiCal v4.5.40
|
||||
# v0.9.18 requires libNGiCal v4.5.38
|
||||
# v0.9.17 requires libNGiCal v4.5.37
|
||||
# v0.9.11 requires libFoundation v1.0.63
|
||||
# v0.9.11 requires libNGExtensions v4.3.125
|
||||
# v0.9.7 requires libGDLAccess v1.1.35
|
||||
@@ -0,0 +1,98 @@
|
||||
{
|
||||
blobTablePattern = "SOGo_$folderId$_blob";
|
||||
quickTablePattern = "SOGo_$folderId$_quick";
|
||||
extractorClassName = "OCSiCalFieldExtractor";
|
||||
|
||||
fields = (
|
||||
{
|
||||
columnName = uid;
|
||||
sqlType = "VARCHAR(256)";
|
||||
allowsNull = NO;
|
||||
},
|
||||
{
|
||||
columnName = startdate;
|
||||
sqlType = "INT";
|
||||
allowsNull = NO;
|
||||
},
|
||||
{
|
||||
columnName = enddate;
|
||||
sqlType = "INT";
|
||||
allowsNull = NO;
|
||||
},
|
||||
{
|
||||
columnName = cylceenddate;
|
||||
sqlType = "INT";
|
||||
allowsNull = YES;
|
||||
},
|
||||
{
|
||||
columnName = title;
|
||||
sqlType = "VARCHAR(1000)";
|
||||
allowsNull = NO;
|
||||
},
|
||||
{
|
||||
columnName = participants;
|
||||
sqlType = "VARCHAR(1000000)";
|
||||
allowsNull = NO;
|
||||
},
|
||||
{
|
||||
columnName = isallday;
|
||||
sqlType = "INT";
|
||||
allowsNull = YES;
|
||||
},
|
||||
{
|
||||
columnName = iscycle;
|
||||
sqlType = "INT";
|
||||
allowsNull = YES;
|
||||
},
|
||||
{
|
||||
columnName = cycleinfo;
|
||||
sqlType = "VARCHAR(1000)";
|
||||
allowsNull = YES;
|
||||
},
|
||||
{
|
||||
columnName = ispublic;
|
||||
sqlType = "INT";
|
||||
allowsNull = NO;
|
||||
},
|
||||
{
|
||||
columnName = isopaque;
|
||||
sqlType = "INT";
|
||||
allowsNull = YES;
|
||||
},
|
||||
{
|
||||
columnName = status;
|
||||
sqlType = "INT";
|
||||
allowsNull = NO;
|
||||
},
|
||||
{
|
||||
columnName = priority;
|
||||
sqlType = "INT";
|
||||
allowsNull = NO;
|
||||
},
|
||||
{
|
||||
columnName = location;
|
||||
sqlType = "VARCHAR(256)";
|
||||
allowsNull = YES;
|
||||
},
|
||||
{
|
||||
columnName = orgmail;
|
||||
sqlType = "VARCHAR(256)";
|
||||
allowsNull = YES;
|
||||
},
|
||||
{
|
||||
columnName = partmails;
|
||||
sqlType = "VARCHAR(100000)";
|
||||
allowsNull = NO;
|
||||
},
|
||||
{
|
||||
columnName = partstates;
|
||||
sqlType = "VARCHAR(256)";
|
||||
allowsNull = NO;
|
||||
},
|
||||
{
|
||||
columnName = sequence;
|
||||
sqlType = "INT";
|
||||
allowsNull = YES;
|
||||
},
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
/*
|
||||
Copyright (C) 2004 SKYRIX Software AG
|
||||
|
||||
This file is part of OpenGroupware.org.
|
||||
|
||||
OGo is free software; you can redistribute it and/or modify it under
|
||||
the terms of the GNU Lesser General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
|
||||
OGo is distributed in the hope that it will be useful, but WITHOUT ANY
|
||||
WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
|
||||
License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with OGo; see the file COPYING. If not, write to the
|
||||
Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
|
||||
02111-1307, USA.
|
||||
*/
|
||||
// $Id$
|
||||
|
||||
#import <Foundation/Foundation.h>
|
||||
#import <Foundation/NSURL.h>
|
||||
|
||||
#include <NGExtensions/NGExtensions.h>
|
||||
|
||||
#if NeXT_RUNTIME || APPLE_RUNTIME
|
||||
# define objc_free(__mem__) free(__mem__)
|
||||
# define objc_malloc(__size__) malloc(__size__)
|
||||
# define objc_calloc(__cnt__, __size__) calloc(__cnt__, __size__)
|
||||
# define objc_realloc(__ptr__, __size__) realloc(__ptr__, __size__)
|
||||
# ifndef sel_eq
|
||||
# define sel_eq(sela,selb) (sela==selb?YES:NO)
|
||||
# endif
|
||||
#endif
|
||||
@@ -0,0 +1,48 @@
|
||||
{
|
||||
blobTablePattern = "SOGo_$folderId$_blob";
|
||||
quickTablePattern = "SOGo_$folderId$_quick";
|
||||
extractorClassName= "OCSContactFieldExtractor";
|
||||
|
||||
fields = (
|
||||
{
|
||||
columnName = givenname;
|
||||
sqlType = "VARCHAR(256)";
|
||||
allowsNull = YES;
|
||||
},
|
||||
{
|
||||
columnName = cn;
|
||||
sqlType = "VARCHAR(256)";
|
||||
allowsNull = YES;
|
||||
},
|
||||
{
|
||||
columnName = sn;
|
||||
sqlType = "VARCHAR(256)";
|
||||
allowsNull = YES;
|
||||
},
|
||||
{
|
||||
columnName = l;
|
||||
sqlType = "VARCHAR(256)";
|
||||
allowsNull = YES;
|
||||
},
|
||||
{
|
||||
columnName = mail;
|
||||
sqlType = "VARCHAR(256)";
|
||||
allowsNull = YES;
|
||||
},
|
||||
{
|
||||
columnName = o;
|
||||
sqlType = "VARCHAR(256)";
|
||||
allowsNull = YES;
|
||||
},
|
||||
{
|
||||
columnName = ou;
|
||||
sqlType = "VARCHAR(256)";
|
||||
allowsNull = YES;
|
||||
},
|
||||
{
|
||||
columnName = telephoneNumber;
|
||||
sqlType = "VARCHAR(256)";
|
||||
allowsNull = YES;
|
||||
},
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
/*
|
||||
Copyright (C) 2004-2005 SKYRIX Software AG
|
||||
|
||||
This file is part of OpenGroupware.org.
|
||||
|
||||
OGo is free software; you can redistribute it and/or modify it under
|
||||
the terms of the GNU Lesser General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
|
||||
OGo is distributed in the hope that it will be useful, but WITHOUT ANY
|
||||
WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
|
||||
License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with OGo; see the file COPYING. If not, write to the
|
||||
Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
|
||||
02111-1307, USA.
|
||||
*/
|
||||
|
||||
#ifndef __OGoContentStore_iCalEntityObject_OCS_H_
|
||||
#define __OGoContentStore_iCalEntityObject_OCS_H_
|
||||
|
||||
#include <NGiCal/NGiCal.h>
|
||||
|
||||
@interface iCalEntityObject (OCS)
|
||||
|
||||
- (int)priorityNumber;
|
||||
|
||||
@end
|
||||
|
||||
#endif /* __OGoContentStore_iCalEntityObject_OCS_H_ */
|
||||
@@ -0,0 +1,43 @@
|
||||
/*
|
||||
Copyright (C) 2004-2005 SKYRIX Software AG
|
||||
|
||||
This file is part of OpenGroupware.org.
|
||||
|
||||
OGo is free software; you can redistribute it and/or modify it under
|
||||
the terms of the GNU Lesser General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
|
||||
OGo is distributed in the hope that it will be useful, but WITHOUT ANY
|
||||
WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
|
||||
License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with OGo; see the file COPYING. If not, write to the
|
||||
Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
|
||||
02111-1307, USA.
|
||||
*/
|
||||
|
||||
#include "iCalEntityObject+OCS.h"
|
||||
#include "common.h"
|
||||
|
||||
@implementation iCalEntityObject (OCS)
|
||||
|
||||
- (int)priorityNumber {
|
||||
NSString *prio;
|
||||
|
||||
prio = [self priority];
|
||||
if(prio) {
|
||||
NSRange r;
|
||||
|
||||
r = [prio rangeOfString:@";"];
|
||||
if(r.length > 0) {
|
||||
prio = [prio substringToIndex:r.location];
|
||||
}
|
||||
return [prio intValue];
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
@end
|
||||
@@ -0,0 +1,35 @@
|
||||
/*
|
||||
Copyright (C) 2004-2005 SKYRIX Software AG
|
||||
|
||||
This file is part of OpenGroupware.org.
|
||||
|
||||
OGo is free software; you can redistribute it and/or modify it under
|
||||
the terms of the GNU Lesser General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
|
||||
OGo is distributed in the hope that it will be useful, but WITHOUT ANY
|
||||
WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
|
||||
License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with OGo; see the file COPYING. If not, write to the
|
||||
Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
|
||||
02111-1307, USA.
|
||||
*/
|
||||
// $Id: iCalRepeatableEntityObject+OCS.h 617 2005-03-01 17:08:11Z znek $
|
||||
|
||||
|
||||
#ifndef __OGoContentStore_iCalRepeatableEntityObject_OCS_H_
|
||||
#define __OGoContentStore_iCalRepeatableEntityObject_OCS_H_
|
||||
|
||||
#include <NGiCal/NGiCal.h>
|
||||
|
||||
@interface iCalRepeatableEntityObject (OCS)
|
||||
|
||||
- (NSString *)cycleInfo;
|
||||
|
||||
@end
|
||||
|
||||
#endif /* __OGoContentStore_iCalRepeatableEntityObject_OCS_H_ */
|
||||
@@ -0,0 +1,89 @@
|
||||
/*
|
||||
Copyright (C) 2004-2005 SKYRIX Software AG
|
||||
|
||||
This file is part of OpenGroupware.org.
|
||||
|
||||
OGo is free software; you can redistribute it and/or modify it under
|
||||
the terms of the GNU Lesser General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
|
||||
OGo is distributed in the hope that it will be useful, but WITHOUT ANY
|
||||
WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
|
||||
License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with OGo; see the file COPYING. If not, write to the
|
||||
Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
|
||||
02111-1307, USA.
|
||||
*/
|
||||
// $Id: iCalRepeatableEntityObject+OCS.m 617 2005-03-01 17:08:11Z znek $
|
||||
|
||||
#include "iCalRepeatableEntityObject+OCS.h"
|
||||
#include "common.h"
|
||||
|
||||
@implementation iCalRepeatableEntityObject (OCS)
|
||||
|
||||
- (NSString *)cycleInfo {
|
||||
NSMutableDictionary *cycleInfo;
|
||||
NSMutableArray *ma;
|
||||
NSArray *a;
|
||||
unsigned count;
|
||||
|
||||
if (![self isRecurrent])
|
||||
return nil;
|
||||
|
||||
cycleInfo = [NSMutableDictionary dictionaryWithCapacity:3];
|
||||
|
||||
/* rules */
|
||||
a = [self recurrenceRules];
|
||||
count = [a count];
|
||||
if (count > 0) {
|
||||
unsigned i;
|
||||
|
||||
ma = [NSMutableArray arrayWithCapacity:count];
|
||||
for (i = 0; i < count; i++) {
|
||||
iCalRecurrenceRule *rule;
|
||||
|
||||
rule = [a objectAtIndex:i];
|
||||
[ma addObject:[rule iCalRepresentation]];
|
||||
}
|
||||
[cycleInfo setObject:ma forKey:@"rules"];
|
||||
}
|
||||
|
||||
/* exception rules */
|
||||
a = [self exceptionRules];
|
||||
count = [a count];
|
||||
if (count > 0) {
|
||||
unsigned i;
|
||||
|
||||
ma = [NSMutableArray arrayWithCapacity:count];
|
||||
for (i = 0; i < count; i++) {
|
||||
iCalRecurrenceRule *rule;
|
||||
|
||||
rule = [a objectAtIndex:i];
|
||||
[ma addObject:[rule iCalRepresentation]];
|
||||
}
|
||||
[cycleInfo setObject:ma forKey:@"exRules"];
|
||||
}
|
||||
|
||||
/* exception dates */
|
||||
a = [self exceptionDates];
|
||||
count = [a count];
|
||||
if (count > 0) {
|
||||
unsigned i;
|
||||
|
||||
ma = [NSMutableArray arrayWithCapacity:count];
|
||||
for (i = 0; i < count; i++) {
|
||||
NSCalendarDate *date;
|
||||
|
||||
date = [a objectAtIndex:i];
|
||||
[ma addObject:[date icalString]];
|
||||
}
|
||||
[cycleInfo setObject:ma forKey:@"exDates"];
|
||||
}
|
||||
|
||||
return [cycleInfo description];
|
||||
}
|
||||
@end
|
||||
@@ -0,0 +1,108 @@
|
||||
http://www.faqs.org/rfcs/rfc2798.html
|
||||
|
||||
Class
|
||||
NAME 'inetOrgPerson'
|
||||
SUP organizationalPerson
|
||||
STRUCTURAL
|
||||
MAY (
|
||||
audio $ businessCategory $ carLicense $ departmentNumber $
|
||||
displayName $ employeeNumber $ employeeType $ givenName $
|
||||
homePhone $ homePostalAddress $ initials $ jpegPhoto $
|
||||
labeledURI $ mail $ manager $ mobile $ o $ pager $
|
||||
photo $ roomNumber $ secretary $ uid $ userCertificate $
|
||||
x500uniqueIdentifier $ preferredLanguage $
|
||||
userSMIMECertificate $ userPKCS12
|
||||
)
|
||||
MUST (
|
||||
cn $ objectClass $ sn
|
||||
)
|
||||
MAY (
|
||||
description $ destinationIndicator $ facsimileTelephoneNumber $
|
||||
internationaliSDNNumber $ l $ ou $ physicalDeliveryOfficeName $
|
||||
postalAddress $ postalCode $ postOfficeBox $
|
||||
preferredDeliveryMethod $ registeredAddress $ seeAlso $
|
||||
st $ street $ telephoneNumber $ teletexTerminalIdentifier $
|
||||
telexNumber $ title $ userPassword $ x121Address
|
||||
)
|
||||
|
||||
Properties (inetOrgPerson + organizationalPerson)
|
||||
businessCategory
|
||||
carLicense
|
||||
departmentNumber
|
||||
destinationIndicator
|
||||
employeeNumber
|
||||
employeeType
|
||||
facsimileTelephoneNumber
|
||||
givenName
|
||||
homePostalAddress
|
||||
initials
|
||||
jpegPhoto
|
||||
l
|
||||
mail
|
||||
manager
|
||||
mobile
|
||||
o
|
||||
objectClass
|
||||
ou
|
||||
pager
|
||||
physicalDeliveryOfficeName
|
||||
postOfficeBox
|
||||
postalCode
|
||||
preferredLanguage
|
||||
registeredAddress
|
||||
roomNumber
|
||||
secretary
|
||||
seeAlso
|
||||
sn
|
||||
street
|
||||
telephoneNumber
|
||||
teletexTerminalIdentifier
|
||||
title
|
||||
uid
|
||||
userCertificate
|
||||
userPKCS12
|
||||
userPassword
|
||||
x121Address
|
||||
audio
|
||||
cn
|
||||
description
|
||||
displayName
|
||||
homePhone
|
||||
internationaliSDNNumber
|
||||
labeledURI
|
||||
photo
|
||||
postalAddress
|
||||
preferredDeliveryMethod
|
||||
st
|
||||
telexNumber
|
||||
userSMIMECertificate
|
||||
x500uniqueIdentifier
|
||||
|
||||
Sample:
|
||||
version: 1
|
||||
dn: cn=Barbara Jensen,ou=Product Development,dc=siroe,dc=com
|
||||
objectClass: top
|
||||
objectClass: person
|
||||
objectClass: organizationalPerson
|
||||
objectClass: inetOrgPerson
|
||||
cn: Barbara Jensen
|
||||
cn: Babs Jensen
|
||||
displayName: Babs Jensen
|
||||
sn: Jensen
|
||||
givenName: Barbara
|
||||
initials: BJJ
|
||||
title: manager, product development
|
||||
uid: bjensen
|
||||
mail: bjensen@siroe.com
|
||||
telephoneNumber: +1 408 555 1862
|
||||
facsimileTelephoneNumber: +1 408 555 1992
|
||||
mobile: +1 408 555 1941
|
||||
roomNumber: 0209
|
||||
carLicense: 6ABC246
|
||||
o: Siroe
|
||||
ou: Product Development
|
||||
departmentNumber: 2604
|
||||
employeeNumber: 42
|
||||
employeeType: full time
|
||||
preferredLanguage: fr, en-gb;q=0.8, en;q=0.7
|
||||
labeledURI: http://www.siroe.com/users/bjensen My Home Page
|
||||
@@ -0,0 +1,30 @@
|
||||
BEGIN:VEVENT
|
||||
DURATION:PT1H
|
||||
ATTENDEE;CN="Elke Bethke";DIR="addressbook://B156F3F0-9CFD-11D8-8561-000
|
||||
D93C1A604:ABPerson":mailto:E.Bethke@Sachsen-Anhalt-Lotto.de
|
||||
ATTENDEE;CN="Erik Doernenburg";DIR="addressbook://B15FCB0F-9CFD-11D8-8561
|
||||
-000D93C1A604:ABPerson":mailto:erik@x101.net
|
||||
ATTENDEE;CN="Christian Schnelle";DIR="addressbook://B1418D4E-9CFD-11D8-8
|
||||
561-000D93C1A604:ABPerson":mailto:cs@enervation.de
|
||||
ATTENDEE;CN="Chris Herrenberger";DIR="addressbook://B14A390C-9CFD-11D8-8
|
||||
561-000D93C1A604:ABPerson":invalid:nomail
|
||||
ATTENDEE;CN="Horst Parplies";DIR="addressbook://B19B47E5-9CFD-11D8-8561-
|
||||
000D93C1A604:ABPerson":mailto:horst.parplies@freenet.de
|
||||
ATTENDEE;CN="Imdat Solak";DIR="addressbook://B19EDB62-9CFD-11D8-8561-000
|
||||
D93C1A604:ABPerson":mailto:imdat@solak.de
|
||||
ATTENDEE;CN="Jens Enders";DIR="addressbook://B1B6819F-9CFD-11D8-8561-000
|
||||
D93C1A604:ABPerson":mailto:jens.enders@skyrix.com
|
||||
ATTENDEE;CN="Jens Muenster";DIR="addressbook://B1BBA42E-9CFD-11D8-8561-00
|
||||
0D93C1A604:ABPerson":mailto:jens.muenster@skyrix.com
|
||||
ATTENDEE;CN="Laurent Pierre";DIR="addressbook://9337C270-A825-11D8-B930-
|
||||
000D93C1A604:ABPerson":mailto:laurent.pierre@linagora.com
|
||||
ATTENDEE;CN="Marcel Weiher";DIR="addressbook://B1F9BB12-9CFD-11D8-8561-0
|
||||
00D93C1A604:ABPerson":mailto:marcel@metaobject.co
|
||||
DTSTAMP:20040520T140002Z
|
||||
UID:BD91C454-AA65-11D8-84CA-000D93C1A604
|
||||
SEQUENCE:3
|
||||
STATUS:CONFIRMED
|
||||
DTSTART;TZID=Europe/Berlin:20040618T160000
|
||||
SUMMARY:SIZE EVENT
|
||||
X-WR-ITIPSTATUSML:UNCLEAN
|
||||
END:VEVENT
|
||||
@@ -0,0 +1,15 @@
|
||||
# $Id$
|
||||
|
||||
include $(GNUSTEP_MAKEFILES)/common.make
|
||||
|
||||
TOOL_NAME = test
|
||||
|
||||
test_OBJC_FILES += test1.m
|
||||
|
||||
ADDITIONAL_TOOL_LIBS += -lOGoContentStore
|
||||
|
||||
ADDITIONAL_LIB_DIRS += -L../../$(GNUSTEP_OBJ_DIR)
|
||||
|
||||
-include GNUmakefile.preamble
|
||||
include $(GNUSTEP_MAKEFILES)/tool.make
|
||||
-include GNUmakefile.postamble
|
||||
@@ -0,0 +1,3 @@
|
||||
// $Id$
|
||||
|
||||
#import <Foundation/Foundation.h>
|
||||
@@ -0,0 +1,31 @@
|
||||
// $Id$
|
||||
|
||||
#include "common.h"
|
||||
|
||||
static void testurl(NSString *s) {
|
||||
NSURL *url;
|
||||
|
||||
url = [NSURL URLWithString:s];
|
||||
NSLog(@"url: %@", url);
|
||||
NSLog(@" login: %@", [url user]);
|
||||
NSLog(@" pwd: %@", [url password]);
|
||||
}
|
||||
|
||||
static void test(void) {
|
||||
testurl(@"http://OGoUser:OGoPwd@localhost/OGo");
|
||||
testurl(@"postgresql://OGoUser:OGoPwd@localhost/OGo");
|
||||
}
|
||||
|
||||
int main(int argc, char **argv, char **env) {
|
||||
NSAutoreleasePool *pool;
|
||||
|
||||
pool = [[NSAutoreleasePool alloc] init];
|
||||
#if LIB_FOUNDATION_LIBRARY
|
||||
[NSProcessInfo initializeWithArguments:argv count:argc environment:env];
|
||||
#endif
|
||||
|
||||
test();
|
||||
|
||||
[pool release];
|
||||
return 0;
|
||||
}
|
||||
@@ -0,0 +1,39 @@
|
||||
Files
|
||||
=====
|
||||
|
||||
appointment-create.psql
|
||||
- this is a template for creating appointment quick/blob tables
|
||||
- not used by code atm
|
||||
|
||||
folderinfo-create.psql
|
||||
- create folder info table (folder registry table)
|
||||
- insert some folders per default:
|
||||
- /Users
|
||||
- /Users/helge
|
||||
- /Users/helge/Calendar
|
||||
|
||||
foldertablecreate-root.psql
|
||||
- insert "/" and "/Users" parent folders (without storage, quick and type)
|
||||
|
||||
foldertablecreate-helge-privcal.psql
|
||||
- create a quick and content table for 'helge/Calendar' folder
|
||||
|
||||
register-agenor-helge-privcal.psql
|
||||
- register folder "/Users/helge/Calendar" folder in the registry table with
|
||||
a link to the proper quick and content tables
|
||||
|
||||
testapt-agenor-helge-privcal.psql
|
||||
- insert a raw iCalendar test appointment in the /Users/helge/Calendar
|
||||
folder quick and content tables
|
||||
|
||||
|
||||
Notes
|
||||
=====
|
||||
|
||||
Listing the folders of a certain user:
|
||||
|
||||
sqlite> SELECT c_path FROM SOGo_folder_info \
|
||||
WHERE c_path2 = 'test.et.di.cete-lyon';
|
||||
/Users/test.et.di.cete-lyon
|
||||
/Users/test.et.di.cete-lyon/Calendar
|
||||
/Users/test.et.di.cete-lyon/Contacts
|
||||
@@ -0,0 +1,30 @@
|
||||
--
|
||||
-- (C) 2004-2005 SKYRIX Software AG
|
||||
--
|
||||
|
||||
CREATE TABLE %s_quick (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, -- the filename
|
||||
uid VARCHAR(256) NOT NULL,
|
||||
startdate INT NOT NULL,
|
||||
enddate INT NOT NULL,
|
||||
title VARCHAR(1000) NOT NULL,
|
||||
participants VARCHAR(100000) NOT NULL, -- the CNs of the participants
|
||||
isallday INT NULL,
|
||||
iscycle INT NULL, -- client needs to fetch to resolve
|
||||
ispublic INT NOT NULL,
|
||||
status INT NOT NULL,
|
||||
isopaque INT NULL,
|
||||
location VARCHAR(256) NULL,
|
||||
orgmail VARCHAR(256) NULL,
|
||||
partmails VARCHAR(100000) NOT NULL, -- the emails of the participants
|
||||
partstates VARCHAR(256) NOT NULL, -- the status of each participant
|
||||
sequence INT NULL -- the iCal sequence
|
||||
);
|
||||
|
||||
CREATE TABLE %s_blob (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, -- the filename
|
||||
c_content VARCHAR(100000) NOT NULL, -- the BLOB
|
||||
c_creationdate INT NOT NULL, -- creation date
|
||||
c_lastmodified INT NOT NULL, -- last modification (UPDATE)
|
||||
c_version INT NOT NULL, -- version counter
|
||||
);
|
||||
@@ -0,0 +1,67 @@
|
||||
--
|
||||
-- (C) 2004-2005 SKYRIX Software AG
|
||||
--
|
||||
-- TODO:
|
||||
-- add a unique constraints on path
|
||||
|
||||
CREATE SEQUENCE SOGo_folder_info_seq;
|
||||
|
||||
DROP TABLE SOGo_folder_info;
|
||||
|
||||
CREATE TABLE SOGo_folder_info (
|
||||
c_folder_id INTEGER
|
||||
DEFAULT nextval('SOGo_folder_info_seq')
|
||||
NOT NULL
|
||||
PRIMARY KEY, -- the primary key
|
||||
c_path VARCHAR(255) NOT NULL, -- the full path to the folder
|
||||
c_path1 VARCHAR(255) NOT NULL, -- parts (for fast queries)
|
||||
c_path2 VARCHAR(255) NULL, -- parts (for fast queries)
|
||||
c_path3 VARCHAR(255) NULL, -- parts (for fast queries)
|
||||
c_path4 VARCHAR(255) NULL, -- parts (for fast queries)
|
||||
c_foldername VARCHAR(255) NOT NULL, -- last path component
|
||||
c_location VARCHAR(2048) NOT NULL, -- URL to folder
|
||||
c_quick_location VARCHAR(2048) NULL, -- URL to quicktable of folder
|
||||
c_folder_type VARCHAR(255) NOT NULL -- the folder type ...
|
||||
);
|
||||
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users',
|
||||
'Users',
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
'Users',
|
||||
'http://OGo:OGo@localhost:5432/OGo/SOGo_user_folder',
|
||||
'http://OGo:OGo@localhost:5432/OGo/SOGo_user_folder_quick',
|
||||
'Container' );
|
||||
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users/helge',
|
||||
'Users',
|
||||
'helge',
|
||||
NULL,
|
||||
NULL,
|
||||
'helge',
|
||||
'http://OGo:OGo@localhost:5432/OGo/SOGo_user_folder',
|
||||
'http://OGo:OGo@localhost:5432/OGo/SOGo_user_folder_quick',
|
||||
'Container' );
|
||||
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users/helge/Calendar',
|
||||
'Users',
|
||||
'helge',
|
||||
'Calendar',
|
||||
NULL,
|
||||
'Calendar',
|
||||
'http://OGo:OGo@localhost:5432/OGo/SOGo_helge_privcal',
|
||||
'http://OGo:OGo@localhost:5432/OGo/SOGo_helge_privcal_quick',
|
||||
'Appointment' );
|
||||
@@ -0,0 +1,62 @@
|
||||
--
|
||||
-- (C) 2005 SKYRIX Software AG
|
||||
--
|
||||
-- TODO:
|
||||
-- add a unique constraints on path
|
||||
|
||||
-- DROP TABLE SOGo_folder_info;
|
||||
|
||||
CREATE TABLE SOGo_folder_info (
|
||||
c_folder_id INTEGER PRIMARY KEY,
|
||||
c_path VARCHAR(255) NOT NULL, /* the full path to the folder */
|
||||
c_path1 VARCHAR(255) NOT NULL, /* parts (for fast queries) */
|
||||
c_path2 VARCHAR(255) NULL, /* parts (for fast queries) */
|
||||
c_path3 VARCHAR(255) NULL, /* parts (for fast queries) */
|
||||
c_path4 VARCHAR(255) NULL, /* parts (for fast queries) */
|
||||
c_foldername VARCHAR(255) NOT NULL, /* last path component */
|
||||
c_location VARCHAR(2048) NOT NULL, /* URL to folder */
|
||||
c_quick_location VARCHAR(2048) NULL, /* URL to quicktable of folder */
|
||||
c_folder_type VARCHAR(255) NOT NULL /* the folder type ... */
|
||||
);
|
||||
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users',
|
||||
'Users',
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
'Users',
|
||||
'sqlite://localhost/tmp/sogo-registry.sqlite/SOGo_user_folder_blob',
|
||||
'sqlite://localhost/tmp/sogo-registry.sqlite/SOGo_user_folder_quick',
|
||||
'Container' );
|
||||
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users/helge',
|
||||
'Users',
|
||||
'helge',
|
||||
NULL,
|
||||
NULL,
|
||||
'helge',
|
||||
'sqlite://localhost/tmp/sogo-registry.sqlite/SOGo_user_folder_blob',
|
||||
'sqlite://localhost/tmp/sogo-registry.sqlite/SOGo_user_folder_quick',
|
||||
'Container' );
|
||||
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users/helge/Calendar',
|
||||
'Users',
|
||||
'helge',
|
||||
'Calendar',
|
||||
NULL,
|
||||
'Calendar',
|
||||
'sqlite://localhost/tmp/sogo-registry.sqlite/SOGo_helge_privcal_blob',
|
||||
'sqlite://localhost/tmp/sogo-registry.sqlite/SOGo_helge_privcal_quick',
|
||||
'Appointment' );
|
||||
@@ -0,0 +1,35 @@
|
||||
--
|
||||
-- (C) 2004 SKYRIX Software AG
|
||||
--
|
||||
|
||||
DROP TABLE SOGo_helge_privcal_quick;
|
||||
DROP TABLE SOGo_helge_privcal;
|
||||
|
||||
CREATE TABLE SOGo_helge_privcal_quick (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, -- the filename
|
||||
uid VARCHAR(256) NOT NULL,
|
||||
startdate INT NOT NULL,
|
||||
enddate INT NOT NULL,
|
||||
cycleenddate INT NULL, -- enddate for cyclic events
|
||||
title VARCHAR(1000) NOT NULL,
|
||||
cycleinfo VARCHAR(1000) NULL, -- property list with cycle infos
|
||||
participants VARCHAR(100000) NOT NULL, -- the CNs of the participants
|
||||
isallday INT NULL,
|
||||
iscycle INT NULL, -- client needs to fetch to resolve
|
||||
ispublic INT NOT NULL,
|
||||
status INT NOT NULL,
|
||||
isopaque INT NULL,
|
||||
location VARCHAR(256) NULL,
|
||||
orgmail VARCHAR(256) NULL,
|
||||
partmails VARCHAR(100000) NOT NULL, -- the emails of the participants
|
||||
partstates VARCHAR(256) NOT NULL, -- the status of each participant
|
||||
sequence INT NULL -- the iCal sequence
|
||||
);
|
||||
|
||||
CREATE TABLE SOGo_helge_privcal (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, -- the filename
|
||||
c_content VARCHAR(100000) NOT NULL, -- the BLOB
|
||||
c_creationdate INT NOT NULL, -- creation date
|
||||
c_lastmodified INT NOT NULL, -- last modification (UPDATE)
|
||||
c_version INT NOT NULL -- version counter
|
||||
);
|
||||
@@ -0,0 +1,36 @@
|
||||
/*
|
||||
(C) 2005 SKYRIX Software AG
|
||||
*/
|
||||
|
||||
DROP TABLE SOGo_helge_privcal_quick;
|
||||
DROP TABLE SOGo_helge_privcal;
|
||||
|
||||
CREATE TABLE SOGo_helge_privcal_quick (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, /* the filename */
|
||||
uid VARCHAR(256) NOT NULL,
|
||||
startdate INT NOT NULL,
|
||||
enddate INT NOT NULL,
|
||||
cycleenddate INT NULL, /* enddate for cyclic events */
|
||||
title VARCHAR(1000) NOT NULL,
|
||||
cycleinfo VARCHAR(1000) NULL, /* property list with cycle infos */
|
||||
participants VARCHAR(100000) NOT NULL, /* the CNs of the participants */
|
||||
isallday INT NULL,
|
||||
iscycle INT NULL, /* client needs to fetch to resolve */
|
||||
ispublic INT NOT NULL,
|
||||
status INT NOT NULL,
|
||||
isopaque INT NULL,
|
||||
priority INT NOT NULL, -- for marking high prio apts
|
||||
location VARCHAR(256) NULL,
|
||||
orgmail VARCHAR(256) NULL,
|
||||
partmails VARCHAR(100000) NOT NULL, /* the emails of the participants */
|
||||
partstates VARCHAR(256) NOT NULL, /* the status of each participant */
|
||||
sequence INT NULL /* the iCal sequence */
|
||||
);
|
||||
|
||||
CREATE TABLE SOGo_helge_privcal_blob (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, /* the filename */
|
||||
c_content VARCHAR(100000) NOT NULL, /* the BLOB */
|
||||
c_creationdate INT NOT NULL, /* creation date */
|
||||
c_lastmodified INT NOT NULL, /* last modification (UPDATE) */
|
||||
c_version INT NOT NULL /* version counter */
|
||||
);
|
||||
@@ -0,0 +1,9 @@
|
||||
# $Id$
|
||||
|
||||
INSERT INTO sogo_folder_info
|
||||
(c_path,c_path1,c_path2,c_path3,c_path4,c_foldername,c_location,c_folder_type)
|
||||
VALUES ('/', '', NULL, NULL, NULL, '', '', 'Container');
|
||||
|
||||
INSERT INTO sogo_folder_info
|
||||
(c_path,c_path1,c_path2,c_path3,c_path4,c_foldername,c_location,c_folder_type)
|
||||
VALUES ('/Users', 'Users', NULL, NULL, NULL, 'Users', '', 'Container');
|
||||
@@ -0,0 +1,27 @@
|
||||
-- $Id$
|
||||
--
|
||||
-- (C) 2004 SKYRIX Software AG
|
||||
--
|
||||
|
||||
DROP TABLE SOGo_test_contacts_quick;
|
||||
DROP TABLE SOGo_test_contacts_blob;
|
||||
|
||||
CREATE TABLE SOGo_test_contacts_quick (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, -- the filename
|
||||
givenname VARCHAR(256),
|
||||
cn VARCHAR(256),
|
||||
sn VARCHAR(256),
|
||||
l VARCHAR(256),
|
||||
mail VARCHAR(256),
|
||||
o VARCHAR(256),
|
||||
ou VARCHAR(256),
|
||||
telephonenumber VARCHAR(256)
|
||||
);
|
||||
|
||||
CREATE TABLE SOGo_test_contacts_blob (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, -- the filename
|
||||
c_content VARCHAR(100000) NOT NULL, -- the BLOB
|
||||
c_creationdate INT NOT NULL, -- creation date
|
||||
c_lastmodified INT NOT NULL, -- last modification (UPDATE)
|
||||
c_version INT NOT NULL -- version counter
|
||||
);
|
||||
@@ -0,0 +1,114 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# Usage: generate-folderinfo-sql-for-users user1 [user2] [user3] [...]
|
||||
#
|
||||
|
||||
DB="/tmp/sogo-registry.sqlite"
|
||||
|
||||
while [ "$1" != "" ]; do
|
||||
USER_ID=$1
|
||||
USER_TABLE=`echo $USER_ID | tr -s [:punct:] _`
|
||||
cat << EOF
|
||||
DELETE FROM SOGo_folder_info WHERE c_path2 = '${USER_ID}';
|
||||
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users/${USER_ID}',
|
||||
'Users',
|
||||
'${USER_ID}',
|
||||
NULL,
|
||||
NULL,
|
||||
'${USER_ID}',
|
||||
'sqlite://localhost${DB}/SOGo_user_folder_blob',
|
||||
'sqlite://localhost${DB}/SOGo_user_folder_quick',
|
||||
'Container' );
|
||||
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users/${USER_ID}/Calendar',
|
||||
'Users',
|
||||
'${USER_ID}',
|
||||
'Calendar',
|
||||
NULL,
|
||||
'Calendar',
|
||||
'sqlite://localhost${DB}/SOGo_${USER_TABLE}_privcal_blob',
|
||||
'sqlite://localhost${DB}/SOGo_${USER_TABLE}_privcal_quick',
|
||||
'Appointment' );
|
||||
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users/${USER_ID}/Contacts',
|
||||
'Users',
|
||||
'${USER_ID}',
|
||||
'Contacts',
|
||||
NULL,
|
||||
'Contacts',
|
||||
'sqlite://localhost${DB}/SOGo_${USER_TABLE}_contacts_blob',
|
||||
'sqlite://localhost${DB}/SOGo_${USER_TABLE}_contacts_quick',
|
||||
'Contact' );
|
||||
|
||||
DROP TABLE SOGo_${USER_TABLE}_privcal_quick;
|
||||
DROP TABLE SOGo_${USER_TABLE}_privcal_blob;
|
||||
|
||||
CREATE TABLE SOGo_${USER_TABLE}_privcal_quick (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, /* the filename */
|
||||
uid VARCHAR(256) NOT NULL,
|
||||
startdate INT NOT NULL,
|
||||
enddate INT NOT NULL,
|
||||
cycleenddate INT NULL, /* enddate for cyclic events */
|
||||
title VARCHAR(1000) NOT NULL,
|
||||
cycleinfo VARCHAR(1000) NULL, /* property list with cycle infos */
|
||||
participants VARCHAR(100000) NOT NULL, /* the CNs of the participants */
|
||||
isallday INT NULL,
|
||||
iscycle INT NULL, /* client needs to fetch to resolve */
|
||||
ispublic INT NOT NULL,
|
||||
status INT NOT NULL,
|
||||
isopaque INT NULL,
|
||||
priority INT NOT NULL, -- for marking high prio apts
|
||||
location VARCHAR(256) NULL,
|
||||
orgmail VARCHAR(256) NULL,
|
||||
partmails VARCHAR(100000) NOT NULL, /* the emails of the participants */
|
||||
partstates VARCHAR(256) NOT NULL, /* the status of each participant */
|
||||
sequence INT NULL /* the iCal sequence */
|
||||
);
|
||||
|
||||
CREATE TABLE SOGo_${USER_TABLE}_privcal_blob (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, /* the filename */
|
||||
c_content VARCHAR(100000) NOT NULL, /* the BLOB */
|
||||
c_creationdate INT NOT NULL, /* creation date */
|
||||
c_lastmodified INT NOT NULL, /* last modification (UPDATE) */
|
||||
c_version INT NOT NULL /* version counter */
|
||||
);
|
||||
|
||||
DROP TABLE SOGo_${USER_TABLE}_contacts_quick;
|
||||
DROP TABLE SOGo_${USER_TABLE}_contacts_blob;
|
||||
|
||||
CREATE TABLE SOGo_${USER_TABLE}_contacts_quick (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, /* the filename */
|
||||
givenname VARCHAR(256),
|
||||
cn VARCHAR(256),
|
||||
sn VARCHAR(256),
|
||||
l VARCHAR(256),
|
||||
mail VARCHAR(256),
|
||||
o VARCHAR(256),
|
||||
ou VARCHAR(256),
|
||||
telephonenumber VARCHAR(256)
|
||||
);
|
||||
|
||||
CREATE TABLE SOGo_${USER_TABLE}_contacts_blob (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, /* the filename */
|
||||
c_content VARCHAR(100000) NOT NULL, /* the BLOB */
|
||||
c_creationdate INT NOT NULL, /* creation date */
|
||||
c_lastmodified INT NOT NULL, /* last modification (UPDATE) */
|
||||
c_version INT NOT NULL /* version counter */
|
||||
);
|
||||
|
||||
EOF
|
||||
shift
|
||||
done
|
||||
@@ -0,0 +1,109 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# Usage: generate-folderinfo-sql-for-users user1 [user2] [user3] [...]
|
||||
#
|
||||
|
||||
DB="/tmp/sogo-registry.sqlite"
|
||||
|
||||
while [ "$1" != "" ]; do
|
||||
USER_ID=$1
|
||||
USER_TABLE=`echo $USER_ID | tr -s [:punct:] _`
|
||||
|
||||
cat << EOF
|
||||
DELETE FROM SOGo_folder_info WHERE c_path2 = '${USER_ID}';
|
||||
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users/${USER_ID}',
|
||||
'Users',
|
||||
'${USER_ID}',
|
||||
NULL,
|
||||
NULL,
|
||||
'${USER_ID}',
|
||||
'sqlite://localhost${DB}/SOGo_user_folder_blob',
|
||||
'sqlite://localhost${DB}/SOGo_user_folder_quick',
|
||||
'Container' );
|
||||
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users/${USER_ID}/Calendar',
|
||||
'Users',
|
||||
'${USER_ID}',
|
||||
'Calendar',
|
||||
NULL,
|
||||
'Calendar',
|
||||
'sqlite://localhost${DB}/SOGo_${USER_TABLE}_privcal',
|
||||
'sqlite://localhost${DB}/SOGo_${USER_TABLE}_privcal',
|
||||
'Appointment' );
|
||||
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users/${USER_ID}/Contacts',
|
||||
'Users',
|
||||
'${USER_ID}',
|
||||
'Contacts',
|
||||
NULL,
|
||||
'Contacts',
|
||||
'sqlite://localhost${DB}/SOGo_${USER_TABLE}_contacts',
|
||||
'sqlite://localhost${DB}/SOGo_${USER_TABLE}_contacts',
|
||||
'Contact' );
|
||||
|
||||
|
||||
DROP TABLE SOGo_${USER_TABLE}_privcal;
|
||||
CREATE TABLE SOGo_${USER_TABLE}_privcal (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, /* the filename */
|
||||
c_content VARCHAR(100000) NOT NULL, /* the BLOB */
|
||||
c_creationdate INT NOT NULL, /* creation date */
|
||||
c_lastmodified INT NOT NULL, /* last modification (UPDATE) */
|
||||
c_version INT NOT NULL, /* version counter */
|
||||
|
||||
/* quick fields */
|
||||
uid VARCHAR(256) NOT NULL,
|
||||
startdate INT NOT NULL,
|
||||
enddate INT NOT NULL,
|
||||
cycleenddate INT NULL, /* enddate for cyclic events */
|
||||
title VARCHAR(1000) NOT NULL,
|
||||
cycleinfo VARCHAR(1000) NULL, /* property list with cycle infos */
|
||||
participants VARCHAR(100000) NOT NULL, /* the CNs of the participants */
|
||||
isallday INT NULL,
|
||||
iscycle INT NULL, /* client needs to fetch to resolve */
|
||||
ispublic INT NOT NULL,
|
||||
status INT NOT NULL,
|
||||
priority INT NOT NULL, -- for marking high prio apts
|
||||
isopaque INT NULL,
|
||||
location VARCHAR(256) NULL,
|
||||
orgmail VARCHAR(256) NULL,
|
||||
partmails VARCHAR(100000) NOT NULL, /* the emails of the participants */
|
||||
partstates VARCHAR(256) NOT NULL, /* the status of each participant */
|
||||
sequence INT NULL /* the iCal sequence */
|
||||
);
|
||||
|
||||
|
||||
DROP TABLE SOGo_${USER_TABLE}_contacts;
|
||||
CREATE TABLE SOGo_${USER_TABLE}_contacts (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, /* the filename */
|
||||
c_content VARCHAR(100000) NOT NULL, /* the BLOB */
|
||||
c_creationdate INT NOT NULL, /* creation date */
|
||||
c_lastmodified INT NOT NULL, /* last modification (UPDATE) */
|
||||
c_version INT NOT NULL, /* version counter */
|
||||
|
||||
/* quick fields */
|
||||
givenname VARCHAR(256),
|
||||
cn VARCHAR(256),
|
||||
sn VARCHAR(256),
|
||||
l VARCHAR(256),
|
||||
mail VARCHAR(256),
|
||||
o VARCHAR(256),
|
||||
ou VARCHAR(256),
|
||||
telephonenumber VARCHAR(256)
|
||||
);
|
||||
|
||||
EOF
|
||||
shift
|
||||
done
|
||||
+125
@@ -0,0 +1,125 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# Usage: generate-folderinfo-sql-for-users user1 [user2] [user3] [...]
|
||||
#
|
||||
|
||||
DB_USER="postgres"
|
||||
DB_PASS=""
|
||||
DB_HOST="agenor-db"
|
||||
DB_PORT="5432"
|
||||
DB_NAME="test"
|
||||
|
||||
|
||||
while [ "$1" != "" ]; do
|
||||
USER_ID=$1
|
||||
USER_TABLE=`echo $USER_ID | tr -s [:punct:] _`
|
||||
cat << EOF
|
||||
--
|
||||
-- (C) 2004 SKYRIX Software AG
|
||||
--
|
||||
-- TODO:
|
||||
-- add a unique constraints on path
|
||||
|
||||
DELETE FROM SOGo_folder_info WHERE c_path2 = '${USER_ID}';
|
||||
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users/${USER_ID}',
|
||||
'Users',
|
||||
'${USER_ID}',
|
||||
NULL,
|
||||
NULL,
|
||||
'${USER_ID}',
|
||||
'http://${DB_USER}:${DB_PASS}@${DB_HOST}:${DB_PORT}/${DB_NAME}/SOGo_user_folder',
|
||||
'http://${DB_USER}:${DB_PASS}@${DB_HOST}:${DB_PORT}/${DB_NAME}/SOGo_user_folder_quick',
|
||||
'Container' );
|
||||
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users/${USER_ID}/Calendar',
|
||||
'Users',
|
||||
'${USER_ID}',
|
||||
'Calendar',
|
||||
NULL,
|
||||
'Calendar',
|
||||
'http://${DB_USER}:${DB_PASS}@${DB_HOST}:${DB_PORT}/${DB_NAME}/SOGo_${USER_TABLE}_privcal',
|
||||
'http://${DB_USER}:${DB_PASS}@${DB_HOST}:${DB_PORT}/${DB_NAME}/SOGo_${USER_TABLE}_privcal_quick',
|
||||
'Appointment' );
|
||||
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users/${USER_ID}/Contacts',
|
||||
'Users',
|
||||
'${USER_ID}',
|
||||
'Contacts',
|
||||
NULL,
|
||||
'Contacts',
|
||||
'http://${DB_USER}:${DB_PASS}@${DB_HOST}:${DB_PORT}/${DB_NAME}/SOGo_${USER_TABLE}_contacts',
|
||||
'http://${DB_USER}:${DB_PASS}@${DB_HOST}:${DB_PORT}/${DB_NAME}/SOGo_${USER_TABLE}_contacts_quick',
|
||||
'Contact' );
|
||||
|
||||
DROP TABLE SOGo_${USER_TABLE}_privcal_quick;
|
||||
DROP TABLE SOGo_${USER_TABLE}_privcal;
|
||||
|
||||
CREATE TABLE SOGo_${USER_TABLE}_privcal_quick (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, -- the filename
|
||||
uid VARCHAR(256) NOT NULL,
|
||||
startdate INT NOT NULL,
|
||||
enddate INT NOT NULL,
|
||||
cycleenddate INT NULL, -- enddate for cyclic events
|
||||
title VARCHAR(1000) NOT NULL,
|
||||
cycleinfo VARCHAR(1000) NULL, -- property list with cycle infos
|
||||
participants VARCHAR(100000) NOT NULL, -- the CNs of the participants
|
||||
isallday INT NULL,
|
||||
iscycle INT NULL, -- client needs to fetch to resolve
|
||||
ispublic INT NOT NULL,
|
||||
status INT NOT NULL,
|
||||
priority INT NOT NULL, -- for marking high prio apts
|
||||
isopaque INT NULL,
|
||||
location VARCHAR(256) NULL,
|
||||
orgmail VARCHAR(256) NULL,
|
||||
partmails VARCHAR(100000) NOT NULL, -- the emails of the participants
|
||||
partstates VARCHAR(256) NOT NULL, -- the status of each participant
|
||||
sequence INT NULL -- the iCal sequence
|
||||
);
|
||||
|
||||
CREATE TABLE SOGo_${USER_TABLE}_privcal (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, -- the filename
|
||||
c_content VARCHAR(100000) NOT NULL, -- the BLOB
|
||||
c_creationdate INT NOT NULL, -- creation date
|
||||
c_lastmodified INT NOT NULL, -- last modification (UPDATE)
|
||||
c_version INT NOT NULL -- version counter
|
||||
);
|
||||
|
||||
DROP TABLE SOGo_${USER_TABLE}_contacts_quick;
|
||||
DROP TABLE SOGo_${USER_TABLE}_contacts;
|
||||
|
||||
CREATE TABLE SOGo_${USER_TABLE}_contacts_quick (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, -- the filename
|
||||
givenname VARCHAR(256),
|
||||
cn VARCHAR(256),
|
||||
sn VARCHAR(256),
|
||||
l VARCHAR(256),
|
||||
mail VARCHAR(256),
|
||||
o VARCHAR(256),
|
||||
ou VARCHAR(256),
|
||||
telephonenumber VARCHAR(256)
|
||||
);
|
||||
|
||||
CREATE TABLE SOGo_${USER_TABLE}_contacts (
|
||||
c_name VARCHAR(256) NOT NULL PRIMARY KEY, -- the filename
|
||||
c_content VARCHAR(100000) NOT NULL, -- the BLOB
|
||||
c_creationdate INT NOT NULL, -- creation date
|
||||
c_lastmodified INT NOT NULL, -- last modification (UPDATE)
|
||||
c_version INT NOT NULL -- version counter
|
||||
);
|
||||
|
||||
EOF
|
||||
shift
|
||||
done
|
||||
@@ -0,0 +1,9 @@
|
||||
--
|
||||
-- (C) 2005 SKYRIX Software AG
|
||||
--
|
||||
|
||||
CREATE TABLE SOGo_user_profile (
|
||||
uid VARCHAR(255) NOT NULL PRIMARY KEY,
|
||||
allowinternet SMALLINT DEFAULT 0,
|
||||
timezonename VARCHAR(255) DEFAULT 'MET'
|
||||
);
|
||||
@@ -0,0 +1,13 @@
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users/helge/Calendar',
|
||||
'Users',
|
||||
'helge',
|
||||
'Calendar',
|
||||
NULL,
|
||||
'Calendar',
|
||||
'http://postgres:@agenor-db:5432/test/SOGo_helge_privcal',
|
||||
'http://postgres:@agenor-db:5432/test/SOGo_helge_privcal_quick',
|
||||
'Appointment' );
|
||||
@@ -0,0 +1,13 @@
|
||||
INSERT INTO SOGo_folder_info
|
||||
( c_path, c_path1, c_path2, c_path3, c_path4, c_foldername,
|
||||
c_location, c_quick_location, c_folder_type )
|
||||
VALUES
|
||||
( '/Users/test.et.di.cete-lyon/Contacts',
|
||||
'Users',
|
||||
'test.et.di.cete-lyon',
|
||||
'Contacts',
|
||||
NULL,
|
||||
'Contacts',
|
||||
'http://postgres:@agenor-db:5432/test/SOGo_test_contacts_blob',
|
||||
'http://postgres:@agenor-db:5432/test/SOGo_test_contacts_quick',
|
||||
'Contact' );
|
||||
@@ -0,0 +1,57 @@
|
||||
--
|
||||
-- (C) 2004 SKYRIX Software AG
|
||||
--
|
||||
|
||||
DELETE FROM SOGo_helge_privcal
|
||||
WHERE c_name = 'BD91C454-AA65-11D8-84CA-000D93C1A604';
|
||||
DELETE FROM SOGo_helge_privcal_quick
|
||||
WHERE c_name = 'BD91C454-AA65-11D8-84CA-000D93C1A604';
|
||||
|
||||
|
||||
|
||||
INSERT INTO SOGo_helge_privcal
|
||||
( c_name, c_creationdate, c_lastmodified, c_version, c_content )
|
||||
VALUES (
|
||||
'BD91C454-AA65-11D8-84CA-000D93C1A604',
|
||||
928383,
|
||||
928383,
|
||||
1,
|
||||
'BEGIN:VEVENT
|
||||
DURATION:PT1H
|
||||
ATTENDEE;CN="Elke Bethke";DIR="addressbook://B156F3F0-9CFD-11D8-8561-000D93C1A604:ABPerson":mailto:E.Bethke@Sachsen-Anhalt-Lotto.de
|
||||
ATTENDEE;CN="Erik Doernenburg";DIR="addressbook://B15FCB0F-9CFD-11D8-8561-000D93C1A604:ABPerson":mailto:erik@x101.net
|
||||
ATTENDEE;CN="Christian Schnelle";DIR="addressbook://B1418D4E-9CFD-11D8-8561-000D93C1A604:ABPerson":mailto:cs@enervation.de
|
||||
ATTENDEE;CN="Chris Herrenberger";DIR="addressbook://B14A390C-9CFD-11D8-8561-000D93C1A604:ABPerson":invalid:nomail
|
||||
ATTENDEE;CN="Horst Parplies";DIR="addressbook://B19B47E5-9CFD-11D8-8561-000D93C1A604:ABPerson":mailto:horst.parplies@freenet.de
|
||||
ATTENDEE;CN="Imdat Solak";DIR="addressbook://B19EDB62-9CFD-11D8-8561-000D93C1A604:ABPerson":mailto:imdat@solak.de
|
||||
ATTENDEE;CN="Jens Enders";DIR="addressbook://B1B6819F-9CFD-11D8-8561-000D93C1A604:ABPerson":mailto:jens.enders@skyrix.com
|
||||
ATTENDEE;CN="Jens Muenster";DIR="addressbook://B1BBA42E-9CFD-11D8-8561-000D93C1A604:ABPerson":mailto:jens.muenster@skyrix.com
|
||||
ATTENDEE;CN="Laurent Pierre";DIR="addressbook://9337C270-A825-11D8-B930-000D93C1A604:ABPerson":mailto:laurent.pierre@linagora.com
|
||||
ATTENDEE;CN="Marcel Weiher";DIR="addressbook://B1F9BB12-9CFD-11D8-8561-000D93C1A604:ABPerson":mailto:marcel@metaobject.co
|
||||
DTSTAMP:20040520T140002Z
|
||||
UID:BD91C454-AA65-11D8-84CA-000D93C1A604
|
||||
SEQUENCE:3
|
||||
STATUS:CONFIRMED
|
||||
DTSTART;TZID=Europe/Berlin:20040814T120000
|
||||
SUMMARY:SIZE EVENT
|
||||
X-WR-ITIPSTATUSML:UNCLEAN
|
||||
END:VEVENT
|
||||
'
|
||||
);
|
||||
|
||||
INSERT INTO SOGo_helge_privcal_quick
|
||||
( c_name, uid, startdate, enddate, title, participants, isallday, iscycle,
|
||||
location, partmails, sequence )
|
||||
VALUES (
|
||||
'BD91C454-AA65-11D8-84CA-000D93C1A604',
|
||||
'BD91C454-AA65-11D8-84CA-000D93C1A604',
|
||||
1092477600,
|
||||
1092481200,
|
||||
'SIZE EVENT',
|
||||
'Elke Bethke, Erik Doernenburg, Christian Schnelle, Chris Herrenberger, Horst Parplies, Imdat Solak, Jens Enders, Jens Muenster, Laurent Pierre, Marcel Weiher',
|
||||
0,
|
||||
0,
|
||||
NULL,
|
||||
'E.Bethke@Sachsen-Anhalt-Lotto.de, erik@x101.net, cs@enervation.de, nomail, horst.parplies@freenet.de, imdat@solak.de, jens.enders@skyrix.com, jens.muenster@skyrix.com, laurent.pierre@linagora.com, marcel@metaobject.com',
|
||||
1
|
||||
);
|
||||
@@ -0,0 +1,63 @@
|
||||
-- $Id$
|
||||
--
|
||||
-- (C) 2004 SKYRIX Software AG
|
||||
--
|
||||
|
||||
DELETE FROM SOGo_helge_privcal
|
||||
WHERE c_name = 'BD91C454-AA65-11D8-84CA-000D93C1A604';
|
||||
DELETE FROM SOGo_helge_privcal_quick
|
||||
WHERE c_name = 'BD91C454-AA65-11D8-84CA-000D93C1A604';
|
||||
|
||||
|
||||
|
||||
INSERT INTO SOGo_helge_privcal
|
||||
( c_name, c_creationdate, c_lastmodified, c_version, c_content )
|
||||
VALUES (
|
||||
'BD91C454-AA65-11D8-84CA-000D93C1A604',
|
||||
928383,
|
||||
928383,
|
||||
1,
|
||||
|
||||
'BEGIN:VEVENT␍2
|
||||
DURATION:PT1H
|
||||
ATTENDEE;CN="Elke Bethke";DIR="addressbook://B156F3F0-9CFD-11D8-8561-000
|
||||
D93C1A604:ABPerson":mailto:E.Bethke@Sachsen-Anhalt-Lotto.de
|
||||
ATTENDEE;CN="Erik Doernenburg";DIR="addressbook://B15FCB0F-9CFD-11D8-8561
|
||||
-000D93C1A604:ABPerson":mailto:erik@x101.net
|
||||
ATTENDEE;CN="Christian Schnelle";DIR="addressbook://B1418D4E-9CFD-11D8-8
|
||||
561-000D93C1A604:ABPerson":mailto:cs@enervation.de
|
||||
ATTENDEE;CN="Chris Herrenberger";DIR="addressbook://B14A390C-9CFD-11D8-8
|
||||
561-000D93C1A604:ABPerson":invalid:nomail
|
||||
ATTENDEE;CN="Horst Parplies";DIR="addressbook://B19B47E5-9CFD-11D8-8561-
|
||||
000D93C1A604:ABPerson":mailto:horst.parplies@freenet.de
|
||||
ATTENDEE;CN="Imdat Solak";DIR="addressbook://B19EDB62-9CFD-11D8-8561-000
|
||||
D93C1A604:ABPerson":mailto:imdat@solak.de
|
||||
ATTENDEE;CN="Jens Enders";DIR="addressbook://B1B6819F-9CFD-11D8-8561-000
|
||||
D93C1A604:ABPerson":mailto:jens.enders@skyrix.com
|
||||
ATTENDEE;CN="Jens Muenster";DIR="addressbook://B1BBA42E-9CFD-11D8-8561-00
|
||||
0D93C1A604:ABPerson":mailto:jens.muenster@skyrix.com
|
||||
ATTENDEE;CN="Laurent Pierre";DIR="addressbook://9337C270-A825-11D8-B930-
|
||||
000D93C1A604:ABPerson":mailto:laurent.pierre@linagora.com
|
||||
ATTENDEE;CN="Marcel Weiher";DIR="addressbook://B1F9BB12-9CFD-11D8-8561-0
|
||||
00D93C1A604:ABPerson":mailto:marcel@metaobject.co
|
||||
DTSTAMP:20040520T140002Z
|
||||
UID:BD91C454-AA65-11D8-84CA-000D93C1A604
|
||||
SEQUENCE:3
|
||||
STATUS:CONFIRMED
|
||||
DTSTART;TZID=Europe/Berlin:20040618T160000
|
||||
SUMMARY:SIZE EVENT
|
||||
X-WR-ITIPSTATUSML:UNCLEAN
|
||||
END:VEVENT
|
||||
'
|
||||
);
|
||||
|
||||
INSERT INTO SOGo_helge_privcal_quick
|
||||
( c_name, uid, startdate, enddate, title, participants )
|
||||
VALUES (
|
||||
'BD91C454-AA65-11D8-84CA-000D93C1A604',
|
||||
'BD91C454-AA65-11D8-84CA-000D93C1A604',
|
||||
8928837,
|
||||
8929000,
|
||||
'SIZE EVENT',
|
||||
'Elke Bethke, Erik Doernenburg, Christian Schnelle, Chris Herrenberger, Horst Parplies, Imdat Solak, Jens Enders, Jens Muenster, Laurent Pierre, Marcel Weiher'
|
||||
);
|
||||
@@ -0,0 +1,33 @@
|
||||
--
|
||||
-- (C) 2004 SKYRIX Software AG
|
||||
--
|
||||
|
||||
DELETE FROM SOGo_test_contacts_blob
|
||||
WHERE c_name = 'contact_donald';
|
||||
DELETE FROM SOGo_test_contacts_quick
|
||||
WHERE c_name = 'contact_donald';
|
||||
|
||||
INSERT INTO SOGo_test_contacts_blob
|
||||
( c_name, c_creationdate, c_lastmodified, c_version, c_content )
|
||||
VALUES (
|
||||
'contact_donald',
|
||||
928383,
|
||||
928383,
|
||||
1,
|
||||
'{
|
||||
givenName="Donald"; cn="Donald Duck"; sn="Duck";
|
||||
l="Entenhausen";
|
||||
mail="dd@entenhausen.com";
|
||||
o="Geldspeicher AG";
|
||||
ou="Support";
|
||||
telephoneNumber="0190-1234567";
|
||||
}'
|
||||
);
|
||||
|
||||
INSERT INTO SOGo_test_contacts_quick
|
||||
( c_name, givenname, cn, sn, l, mail, o, ou, telephoneNumber )
|
||||
VALUES (
|
||||
'contact_donald', 'Donald', 'Donald Duck', 'Duck', 'Entenhausen',
|
||||
'dd@entenhausen.com', 'Geldspeicher AG', 'Support',
|
||||
'0190-1234567'
|
||||
);
|
||||
@@ -0,0 +1,123 @@
|
||||
/*
|
||||
Copyright (C) 2005 SKYRIX Software AG
|
||||
|
||||
This file is part of SOGo.
|
||||
|
||||
SOGo is free software; you can redistribute it and/or modify it under
|
||||
the terms of the GNU Lesser General Public License as published by the
|
||||
Free Software Foundation; either version 2, or (at your option) any
|
||||
later version.
|
||||
|
||||
SOGo is distributed in the hope that it will be useful, but WITHOUT ANY
|
||||
WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
|
||||
License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with SOGo; see the file COPYING. If not, write to the
|
||||
Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
|
||||
02111-1307, USA.
|
||||
*/
|
||||
|
||||
|
||||
#import <Foundation/NSObject.h>
|
||||
|
||||
@class NSArray;
|
||||
|
||||
@interface TestQuickExtract : NSObject
|
||||
|
||||
- (int)runWithArguments:(NSArray *)_args;
|
||||
|
||||
@end
|
||||
|
||||
#include <GDLContentStore/GCSFieldExtractor.h>
|
||||
#include "common.h"
|
||||
|
||||
@implementation TestQuickExtract
|
||||
|
||||
- (int)usage:(NSArray *)_args {
|
||||
fprintf(stderr, "usage: %s <ExtractorClassName> <file1> <file2>\n",
|
||||
[[_args objectAtIndex:0] cString]);
|
||||
return 1;
|
||||
}
|
||||
|
||||
- (void)extractQuickInfoFromFileAtPath:(NSString *)_path
|
||||
usingExtractorClass:(Class)_clazz
|
||||
{
|
||||
GCSFieldExtractor *extractor;
|
||||
NSString *content;
|
||||
NSDictionary *quickInfo;
|
||||
|
||||
if ((content = [NSString stringWithContentsOfFile:_path]) == nil) {
|
||||
fprintf(stderr, "ERROR: could not open file: %s\n", [_path cString]);
|
||||
return;
|
||||
}
|
||||
|
||||
extractor = [[_clazz alloc] init];
|
||||
quickInfo = [[extractor extractQuickFieldsFromContent:content] retain];
|
||||
[extractor release]; extractor = nil;
|
||||
|
||||
if ([quickInfo count] == 0) {
|
||||
fprintf(stderr, "ERROR: could not extract quickfields from file: %s\n",
|
||||
[_path cString]);
|
||||
return;
|
||||
}
|
||||
|
||||
printf("File: %s\n", [_path cString]);
|
||||
printf("**************************************************\n");
|
||||
printf("%s\n", [[quickInfo description] cString]);
|
||||
|
||||
[quickInfo release];
|
||||
}
|
||||
|
||||
- (void)extractQuickInfoFromFiles:(NSEnumerator *)_pathes
|
||||
usingExtractorClass:(Class)_clazz
|
||||
{
|
||||
NSString *path;
|
||||
|
||||
while ((path = [_pathes nextObject]) != nil)
|
||||
[self extractQuickInfoFromFileAtPath:path usingExtractorClass:_clazz];
|
||||
}
|
||||
|
||||
- (int)runWithArguments:(NSArray *)_args {
|
||||
NSEnumerator *e;
|
||||
Class clazz;
|
||||
|
||||
if ([_args count] < 3)
|
||||
return [self usage:_args];
|
||||
|
||||
if ((clazz = NSClassFromString([_args objectAtIndex:1])) == Nil) {
|
||||
fprintf(stderr, "ERROR: did not find extractor class: %s\n",
|
||||
[[_args objectAtIndex:1] cString]);
|
||||
return 2;
|
||||
}
|
||||
|
||||
e = [_args objectEnumerator];
|
||||
[e nextObject]; // skip toolname
|
||||
[e nextObject]; // skip classname
|
||||
|
||||
[self extractQuickInfoFromFiles:e usingExtractorClass:clazz];
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@end /* TestQuickExtract */
|
||||
|
||||
|
||||
int main(int argc, char **argv, char **env) {
|
||||
NSAutoreleasePool *pool;
|
||||
TestQuickExtract *tool;
|
||||
int rc;
|
||||
|
||||
pool = [[NSAutoreleasePool alloc] init];
|
||||
#if LIB_FOUNDATION_LIBRARY
|
||||
[NSProcessInfo initializeWithArguments:argv count:argc environment:env];
|
||||
#endif
|
||||
|
||||
tool = [[TestQuickExtract alloc] init];
|
||||
rc = [tool runWithArguments:
|
||||
[[NSProcessInfo processInfo] argumentsWithoutDefaults]];
|
||||
[tool release];
|
||||
[pool release];
|
||||
return rc;
|
||||
}
|
||||
Reference in New Issue
Block a user