mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-10-05 20:10:33 +00:00
Monotone-Parent: 61e6d0133bf0d45c09767727617ba746f65a28b9
Monotone-Revision: 54ac2dbf42dee286f64da8b9b3c4567570b00258 Monotone-Author: wsourdeau@inverse.ca Monotone-Date: 2012-08-13T15:29:44 Monotone-Branch: ca.inverse.sogo
This commit is contained in:
@@ -1,5 +1,8 @@
|
||||
2012-08-13 Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
|
||||
* SoObjects/SOGo/NSString+Utilities.m
|
||||
(-stringByReplacingPrefix:withPrefix:): new self-explicit method.
|
||||
|
||||
* OpenChange/SOGoMAPIDBFolder.m
|
||||
(-childKeysOfType:includeDeleted:matchingQualifier:andSortOrderings:):
|
||||
records now have a c_parent_path column in order to avoid fetch
|
||||
|
||||
@@ -74,7 +74,8 @@
|
||||
|
||||
/* substrings */
|
||||
- (NSUInteger) countOccurrencesOfString: (NSString *) substring;
|
||||
|
||||
- (NSString *) stringByReplacingPrefix: (NSString *) oldPrefix
|
||||
withPrefix: (NSString *) newPrefix;
|
||||
|
||||
/* Those methods provide symmetric enc-/decryption via a XOR operation */
|
||||
- (NSString *) encryptWithKey: (NSString *) theKey;
|
||||
|
||||
@@ -560,6 +560,24 @@ static int cssEscapingCount;
|
||||
return count;
|
||||
}
|
||||
|
||||
- (NSString *) stringByReplacingPrefix: (NSString *) oldPrefix
|
||||
withPrefix: (NSString *) newPrefix
|
||||
{
|
||||
NSUInteger oldPrefixLength;
|
||||
NSString *newString;
|
||||
|
||||
if (![self hasPrefix: oldPrefix])
|
||||
[NSException raise: NSInvalidArgumentException
|
||||
format: @"string does not have the specified prefix"];
|
||||
|
||||
oldPrefixLength = [oldPrefix length];
|
||||
newString = [NSString stringWithFormat: @"%@%@",
|
||||
newPrefix,
|
||||
[self substringFromIndex: oldPrefixLength]];
|
||||
|
||||
return newString;
|
||||
}
|
||||
|
||||
- (NSString *) encryptWithKey: (NSString *) theKey
|
||||
{
|
||||
NSMutableData *encryptedPassword;
|
||||
|
||||
Reference in New Issue
Block a user