File: Element.h

package info (click to toggle)
agenda.app 0.47-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,008 kB
  • sloc: objc: 8,103; makefile: 16; sh: 5
file content (67 lines) | stat: -rw-r--r-- 1,684 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
/* emacs buffer mode hint -*- objc -*- */

#import "config.h"
#import "MemoryStore.h"
#import "Date.h"

/*
  icalproperty_class

  ICAL_CLASS_X = 10006,
  ICAL_CLASS_PUBLIC = 10007,
  ICAL_CLASS_PRIVATE = 10008,
  ICAL_CLASS_CONFIDENTIAL = 10009,
  ICAL_CLASS_NONE = 10010
*/

@class Alarm;

@interface Element : NSObject <NSCoding>
{
  id <MemoryStore> _store;
  NSString *_uid;
  NSString *_summary;
  NSAttributedString *_text;
  icalproperty_class _classification;
  Date *_stamp;
  NSMutableArray *_alarms;
  NSMutableArray *_categories;
}

+ (NSArray *)availableCategories;

- (id)initWithSummary:(NSString *)summary;
- (void)generateUID;
- (id <MemoryStore>)store;
- (NSAttributedString *)text;
- (NSString *)summary;
- (NSString *)UID;
- (icalproperty_class)classification;
- (Date *)dateStamp;

- (void)setStore:(id <MemoryStore>)store;
- (void)setText:(NSAttributedString *)text;
- (void)setSummary:(NSString *)summary;
- (void)setUID:(NSString *)uid;
- (void)setClassification:(icalproperty_class)classification;
- (void)setDateStamp:(Date *)stamp;

- (BOOL)hasAlarms;
- (NSArray *)alarms;
- (void)setAlarms:(NSArray *)alarms;
- (void)addAlarm:(Alarm *)alarm;
- (void)removeAlarm:(Alarm *)alarm;
- (Date *)nextActivationDate;

- (NSArray *)categories;
- (void)setCategories:(NSArray *)categories;
- (void)addCategory:(NSString *)category;
- (void)removeCategory:(NSString *)category;
- (BOOL)inCategory:(NSString *)category;

- (id)initWithICalComponent:(icalcomponent *)ic;
- (icalcomponent *)asICalComponent;
- (void)deleteProperty:(icalproperty_kind)kind fromComponent:(icalcomponent *)ic;
- (BOOL)updateICalComponent:(icalcomponent *)ic;
- (int)iCalComponentType;
@end