2 Copyright (C) 2005 SKYRIX Software AG
4 This file is part of OpenGroupware.org.
6 OGo is free software; you can redistribute it and/or modify it under
7 the terms of the GNU Lesser General Public License as published by the
8 Free Software Foundation; either version 2, or (at your option) any
11 OGo is distributed in the hope that it will be useful, but WITHOUT ANY
12 WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
14 License for more details.
16 You should have received a copy of the GNU Lesser General Public
17 License along with OGo; see the file COPYING. If not, write to the
18 Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
22 #include "SOGoMailIdentity.h"
25 @implementation SOGoMailIdentity
29 [self->email release];
30 [self->replyTo release];
31 [self->organization release];
32 [self->signature release];
33 [self->vCard release];
34 [self->sentFolderName release];
35 [self->sentBCC release];
36 [self->draftsFolderName release];
37 [self->templatesFolderName release];
43 - (void)setName:(NSString *)_value {
44 ASSIGNCOPY(self->name, _value);
50 - (void)setEmail:(NSString *)_value {
51 ASSIGNCOPY(self->email, _value);
57 - (void)setReplyTo:(NSString *)_value {
58 ASSIGNCOPY(self->replyTo, _value);
60 - (NSString *)replyTo {
64 - (void)setOrganization:(NSString *)_value {
65 ASSIGNCOPY(self->organization, _value);
67 - (NSString *)organization {
68 return self->organization;
71 - (void)setSignature:(NSString *)_value {
72 ASSIGNCOPY(self->signature, _value);
74 - (NSString *)signature {
75 return self->signature;
77 - (BOOL)hasSignature {
78 return [[self signature] isNotEmpty];
81 - (void)setVCard:(NSString *)_value {
82 ASSIGNCOPY(self->vCard, _value);
88 return [[self vCard] isNotEmpty];
91 - (void)setSentFolderName:(NSString *)_value {
92 ASSIGNCOPY(self->sentFolderName, _value);
94 - (NSString *)sentFolderName {
95 return self->sentFolderName;
98 - (void)setSentBCC:(NSString *)_value {
99 ASSIGNCOPY(self->sentBCC, _value);
101 - (NSString *)sentBCC {
102 return self->sentBCC;
105 - (void)setDraftsFolderName:(NSString *)_value {
106 ASSIGNCOPY(self->draftsFolderName, _value);
108 - (NSString *)draftsFolderName {
109 return self->draftsFolderName;
112 - (void)setTemplatesFolderName:(NSString *)_value {
113 ASSIGNCOPY(self->templatesFolderName, _value);
115 - (NSString *)templatesFolderName {
116 return self->templatesFolderName;
121 - (NSString *)description {
124 ms = [NSMutableString stringWithCapacity:128];
125 [ms appendFormat:@"<0x%08X[%@]:", self, NSStringFromClass([self class])];
127 if (self->name != nil) [ms appendFormat:@" name='%@'", self->name];
128 if (self->email != nil) [ms appendFormat:@" email='%@'", self->email];
130 if (self->sentFolderName != nil)
131 [ms appendFormat:@" sent='%@'", self->sentFolderName];
133 if ([self->sentBCC length] > 0) [ms appendString:@" sent-bcc"];
134 if ([self->vCard length] > 0) [ms appendString:@" vcard"];
136 [ms appendString:@">"];
140 @end /* SOGoMailIdentity */