author | zautrix <zautrix> | 2004-06-26 19:01:18 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-06-26 19:01:18 (UTC) |
commit | b9aad1f15dc600e4dbe4c62d3fcced6363188ba3 (patch) (unidiff) | |
tree | 2c3d4004fb21c72cba65793859f9bcd8ffd3a49c /libical/src/libicalss/icalfileset.h | |
download | kdepimpi-b9aad1f15dc600e4dbe4c62d3fcced6363188ba3.zip kdepimpi-b9aad1f15dc600e4dbe4c62d3fcced6363188ba3.tar.gz kdepimpi-b9aad1f15dc600e4dbe4c62d3fcced6363188ba3.tar.bz2 |
Initial revision
Diffstat (limited to 'libical/src/libicalss/icalfileset.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | libical/src/libicalss/icalfileset.h | 107 |
1 files changed, 107 insertions, 0 deletions
diff --git a/libical/src/libicalss/icalfileset.h b/libical/src/libicalss/icalfileset.h new file mode 100644 index 0000000..51254d2 --- a/dev/null +++ b/libical/src/libicalss/icalfileset.h | |||
@@ -0,0 +1,107 @@ | |||
1 | /* -*- Mode: C -*- */ | ||
2 | /*====================================================================== | ||
3 | FILE: icalfileset.h | ||
4 | CREATOR: eric 23 December 1999 | ||
5 | |||
6 | |||
7 | $Id$ | ||
8 | $Locker$ | ||
9 | |||
10 | (C) COPYRIGHT 2000, Eric Busboom, http://www.softwarestudio.org | ||
11 | |||
12 | This program is free software; you can redistribute it and/or modify | ||
13 | it under the terms of either: | ||
14 | |||
15 | The LGPL as published by the Free Software Foundation, version | ||
16 | 2.1, available at: http://www.fsf.org/copyleft/lesser.html | ||
17 | |||
18 | Or: | ||
19 | |||
20 | The Mozilla Public License Version 1.0. You may obtain a copy of | ||
21 | the License at http://www.mozilla.org/MPL/ | ||
22 | |||
23 | The Original Code is eric. The Initial Developer of the Original | ||
24 | Code is Eric Busboom | ||
25 | |||
26 | |||
27 | ======================================================================*/ | ||
28 | |||
29 | #ifndef ICALFILESET_H | ||
30 | #define ICALFILESET_H | ||
31 | |||
32 | #include "icalerror.h" | ||
33 | #include "ical.h" | ||
34 | #include "icalset.h" | ||
35 | #include "icalgauge.h" | ||
36 | |||
37 | extern int icalfileset_safe_saves; | ||
38 | |||
39 | typedef void icalfileset; | ||
40 | |||
41 | |||
42 | /* icalfileset | ||
43 | icalfilesetfile | ||
44 | icalfilesetdir | ||
45 | */ | ||
46 | |||
47 | |||
48 | icalfileset* icalfileset_new(const char* path); | ||
49 | |||
50 | #ifdef _WIN32 | ||
51 | #define mode_t int | ||
52 | #endif | ||
53 | |||
54 | /* Like _new, but takes open() flags for opening the file */ | ||
55 | icalfileset* icalfileset_new_open(const char* path, | ||
56 | int flags, mode_t mode); | ||
57 | |||
58 | void icalfileset_free(icalfileset* cluster); | ||
59 | |||
60 | const char* icalfileset_path(icalfileset* cluster); | ||
61 | |||
62 | /* Mark the cluster as changed, so it will be written to disk when it | ||
63 | is freed. Commit writes to disk immediately. */ | ||
64 | void icalfileset_mark(icalfileset* cluster); | ||
65 | icalerrorenum icalfileset_commit(icalfileset* cluster); | ||
66 | |||
67 | icalerrorenum icalfileset_add_component(icalfileset* cluster, | ||
68 | icalcomponent* child); | ||
69 | |||
70 | icalerrorenum icalfileset_remove_component(icalfileset* cluster, | ||
71 | icalcomponent* child); | ||
72 | |||
73 | int icalfileset_count_components(icalfileset* cluster, | ||
74 | icalcomponent_kind kind); | ||
75 | |||
76 | /* Restrict the component returned by icalfileset_first, _next to those | ||
77 | that pass the gauge. _clear removes the gauge */ | ||
78 | icalerrorenum icalfileset_select(icalfileset* store, icalgauge* gauge); | ||
79 | void icalfileset_clear(icalfileset* store); | ||
80 | |||
81 | /* Get and search for a component by uid */ | ||
82 | icalcomponent* icalfileset_fetch(icalfileset* cluster, const char* uid); | ||
83 | int icalfileset_has_uid(icalfileset* cluster, const char* uid); | ||
84 | icalcomponent* icalfileset_fetch_match(icalfileset* set, icalcomponent *c); | ||
85 | |||
86 | |||
87 | /* Modify components according to the MODIFY method of CAP. Works on | ||
88 | the currently selected components. */ | ||
89 | icalerrorenum icalfileset_modify(icalfileset* store, icalcomponent *oldcomp, | ||
90 | icalcomponent *newcomp); | ||
91 | |||
92 | /* Iterate through components. If a guage has been defined, these | ||
93 | will skip over components that do not pass the gauge */ | ||
94 | |||
95 | icalcomponent* icalfileset_get_current_component (icalfileset* cluster); | ||
96 | icalcomponent* icalfileset_get_first_component(icalfileset* cluster); | ||
97 | icalcomponent* icalfileset_get_next_component(icalfileset* cluster); | ||
98 | /* Return a reference to the internal component. You probably should | ||
99 | not be using this. */ | ||
100 | |||
101 | icalcomponent* icalfileset_get_component(icalfileset* cluster); | ||
102 | |||
103 | |||
104 | #endif /* !ICALFILESET_H */ | ||
105 | |||
106 | |||
107 | |||