rfm@gnu.org
)Copyright: (C) 2003 Free Software Foundation, Inc.
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
Description forthcoming.
Method summaryDescription forthcoming.
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
Description forthcoming.
Method summaryDescription forthcoming.
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
Extension methods for the NSCalendarDate class
Method summary
The ISO standard week of the year is based on the first
week of the year being that week (starting on monday)
for which the thursday is on or after the first of
january.
This has the effect that, if
january first is a friday, saturday or sunday, the
days of that week (up to and including the sunday) are
considered to be in week 53 of the preceeding
year. Similarly if the last day of the year is a
monday tuesday or wednesday, these days are part of
week 1 of the next year.
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
Extension methods for the NSData class
Method summary
Returns an NSString object containing an ASCII
hexadecimal representation of the receiver.
This means that the returned object will contain
exactly twice as many characters as there are bytes
as the receiver, as each byte in the receiver is
represented by two hexadecimal digits.
The high order four bits of each byte is encoded before
the low order four bits. Capital letters 'A' to 'F' are
used to represent values from 10 to 15.
If you
need the hexadecimal representation as raw byte data,
use code like -
hexData = [[sourceData hexadecimalRepresentation] dataUsingEncoding: NSASCIIStringEncoding];
Initialises the receiver with the supplied
string data which contains a hexadecimal
coding of the bytes. The parsing of the
string is fairly tolerant, ignoring
whitespace and permitting both upper and lower
case hexadecimal digits (the
-hexadecimalRepresentation
method produces a string using only
uppercase digits with no white spaqce).
If
the string does not contain one or more
pairs of hexadecimal digits then an exception is
raised.
Creates an MD5 digest of the information stored in
the receiver and returns it as an autoreleased 16 byte
NSData object.
If you need to produce a
digest of string information, you need to decide
what character encoding is to be used and convert your
string to a data object of that encoding type first
using the
[NSString -dataUsingEncoding:]
method -
myDigest = [[myString dataUsingEncoding: NSUTF8StringEncoding] md5Digest];If you need to use the digest in a human readable form, you will probably want it to be seen as 32 hexadecimal digits, and can do that using the -hexadecimalRepresentation method.
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
Description forthcoming.
Method summaryDescription forthcoming.
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
Description forthcoming.
Method summaryDescription forthcoming.
Description forthcoming.
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
Description forthcoming.
Method summaryDescription forthcoming.
Description forthcoming.
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
Description forthcoming.
Method summary
Initializes the id pointed to by
location with a new instance of the
receiver's class in a thread safe manner, unless
it has been previously initialized. Returns the contents
pointed to by location. The
location is considered unintialized if it
contains nil
.
This method is
used in the GS_INITIALIZED_LOCK macro to initialize
lock variables when it cannot be insured that they can
be initialized in a thread safe environment.
NSLock *my_lock = nil; void function (void) { [GS_INITIALIZED_LOCK(my_lock, NSLock) lock]; do_work (); [my_lock unlock]; }
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
GNUstep specific (non-standard) additions to the NSMutableString class.
Method summaryRemoves the specified prefix from the string. Raises an exception if the prefix is not present.
Removes the specified suffix from the string. Raises an exception if the suffix is not present.
Replaces all occurrances of the string
replace with the string by in
the receiver.
Has no effect if
replace does not occur within the
receiver. NB. an empty string is not considered
to exist within the receiver.
Calls -
replaceOccurrencesOfString:withString:options:range:
passing zero for the options and a range from 0
with the length of the receiver.
Removes all leading white space from the receiver.
Removes all leading or trailing white space from the receiver.
Removes all trailing white space from the receiver.
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
GNUstep specific (non-standard) additions to the NSNumber class.
Method summaryDescription forthcoming.
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
Extension methods for the NSObject class
Method summaryWARNING: The -compare: method for NSObject is deprecated due to subclasses declaring the same selector with conflicting signatures. Comparision of arbitrary objects is not just meaningless but also dangerous as most concrete implementations expect comparable objects as arguments often accessing instance variables directly. This method will be removed in a future release.
Description forthcoming.
Description forthcoming.
Description forthcoming.
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
Description forthcoming.
Method summaryDescription forthcoming.
Description forthcoming.
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
Description forthcoming.
Method summaryDescription forthcoming.
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
Description forthcoming.
Method summary
Initializes the id pointed to by
location with a new instance of the
receiver's class in a thread safe manner, unless
it has been previously initialized. Returns the contents
pointed to by location. The
location is considered unintialized if it
contains nil
.
This method is
used in the GS_INITIALIZED_LOCK macro to initialize
lock variables when it cannot be insured that they can
be initialized in a thread safe environment.
NSLock *my_lock = nil; void function (void) { [GS_INITIALIZED_LOCK(my_lock, NSRecursiveLock) lock]; do_work (); [my_lock unlock]; }
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
GNUstep specific (non-standard) additions to the NSString class.
Method summaryReturns an autoreleased string initialized with -initWithFormat:arguments: .
Returns a string formed by removing the prefix string from the receiver. Raises an exception if the prefix is not present.
Returns a string formed by removing the suffix string from the receiver. Raises an exception if the suffix is not present.
Returns a string in which any (and all) occurrances of replace in the receiver have been replaced with by. Returns the receiver if replace does not occur within the receiver. NB. an empty string is not considered to exist within the receiver.
Returns a string formed by removing leading white space from the receiver.
Returns a string formed by removing both leading and trailing white space from the receiver.
Returns a string formed by removing trailing white space from the receiver.
- Declared in:
- GNUstepBase/GSCategories.h
Standards:
- MacOS-X
- OpenStep
- GNUstep
Description forthcoming.
Method summaryDescription forthcoming.
Description forthcoming.