Camel.StoreSummary¶
| Subclasses: | None | 
|---|
Methods¶
| Inherited: | GObject.Object (37) | 
|---|---|
| Structs: | GObject.ObjectClass (5) | 
| class | new() | 
| add(info) | |
| array() | |
| array_free(array) | |
| connect_folder_summary(path, folder_summary) | |
| count() | |
| disconnect_folder_summary(folder_summary) | |
| info_unref(info) | |
| load() | |
| remove(info) | |
| remove_path(path) | |
| save() | |
| set_filename(filename) | |
| sort(compare_func, *user_data) | |
| touch() | 
Virtual Methods¶
| Inherited: | GObject.Object (7) | 
|---|
| do_store_info_free(info) | |
| do_store_info_save(file, info) | |
| do_store_info_set_string(info, type, value) | |
| do_summary_header_load(file) | |
| do_summary_header_save(file) | 
Properties¶
None
Signals¶
| Inherited: | GObject.Object (1) | 
|---|
Class Details¶
- 
class Camel.StoreSummary(**kwargs)¶
- Bases: - GObject.Object- Abstract: - No - Structure: - Camel.StoreSummaryClass- 
classmethod new()¶
- Returns: - a new - Camel.StoreSummaryobject- Return type: - Camel.StoreSummary- Create a new - Camel.StoreSummaryobject.
 - 
add(info)¶
- Parameters: - info ( - Camel.StoreInfo) – a- Camel.StoreInfo- The info record should have been generated by calling one of the info_new_*() functions, as it will be free’d based on the summary class. And MUST NOT be allocated directly using malloc. 
 - 
array()¶
- Returns: - the summary array - Return type: - [ - Camel.StoreInfo]- Obtain a copy of the summary array. This is done atomically, so cannot contain empty entries. - It must be freed using - Camel.StoreSummary.array_free().
 - 
array_free(array)¶
- Parameters: - array ([ - Camel.StoreInfo]) – the summary array as gotten from- Camel.StoreSummary.array()- Free the folder summary array. 
 - 
connect_folder_summary(path, folder_summary)¶
- Parameters: - path (str) – used path for folder_summary
- folder_summary (Camel.FolderSummary) – aCamel.FolderSummaryobject
 - Returns: - Whether successfully connect callbacks for count change notifications. - Return type: - Connects listeners for count changes on folder_summary to keep Camel.StoreInfo.total and Camel.StoreInfo.unread in sync transparently. The folder_summary is stored in self as path. Use - Camel.StoreSummary.disconnect_folder_summary() to disconnect from listening.- New in version 3.4. 
- path (
 - 
count()¶
- Returns: - the number of items - inthe summary.- Return type: - int- Get the number of summary items stored in this summary. 
 - 
disconnect_folder_summary(folder_summary)¶
- Parameters: - folder_summary ( - Camel.FolderSummary) – a- Camel.FolderSummaryobject- Returns: - Whether such connection existed and whether was successfully removed. - Return type: - bool- Diconnects count change listeners previously connected by - Camel.StoreSummary.connect_folder_summary().- New in version 3.4. 
 - 
info_unref(info)¶
- Parameters: - info ( - Camel.StoreInfo) – a- Camel.StoreInfo- Unref and potentially free info, and all associated memory. 
 - 
remove(info)¶
- Parameters: - info ( - Camel.StoreInfo) – a- Camel.StoreInfo- Remove a specific info record from the summary. 
 - 
remove_path(path)¶
- Parameters: - path ( - str) – item path- Remove a specific info record from the summary, by path. 
 - 
save()¶
- Returns: - 0 on succes or -1 on fail - Return type: - int- Writes the summary to disk. The summary is only written if changes have occurred. 
 - 
set_filename(filename)¶
- Parameters: - filename ( - str) – a filename- Set the filename where the summary will be loaded to/saved from. 
 - 
sort(compare_func, *user_data)¶
- Parameters: - compare_func (GLib.CompareDataFunc) – a compare function
- user_data (objectorNone) – user data passed to the compare_func
 - Sorts the array of the folders using the compare_func. - New in version 3.24. 
- compare_func (
 - 
touch()¶
- Mark the summary as changed, so that a save will force it to be written back to disk. 
 - 
do_store_info_free(info) virtual¶
- Parameters: - info ( - Camel.StoreInfo) –
 - 
do_store_info_save(file, info) virtual¶
- Parameters: - file (objectorNone) –
- info (Camel.StoreInfo) –
 - Return type: 
- file (
 - 
do_store_info_set_string(info, type, value) virtual¶
- Parameters: - info (Camel.StoreInfo) –
- type (int) –
- value (str) –
 
- info (
 
- 
classmethod