Samond Classes Library 1.2.6-STABLE build 219
|
Wrapper class for data objects. More...
#import <SCData.h>
Creating Class Instances | |
(instancetype) | + dataWithData: |
Initializing Class Instances | |
(instancetype) | - initWithData: |
Getting Data | |
(void) | - getBytes:length: |
(SCByte) | - getByte |
(SCUByte) | - getUByte |
(SCShort) | - getShort |
(SCUShort) | - getUShort |
(SCInteger) | - getInteger |
(SCUInteger) | - getUInteger |
(SCLong) | - getLong |
(SCULong) | - getULong |
(char) | - getChar |
(unichar) | - getUnichar |
(const char *) | - getCharString |
(BOOL) | - getBool |
(SCFloat) | - getFloat |
(SCDouble) | - getDouble |
(NSInteger) | - getNSInteger |
(NSUInteger) | - getNSUInteger |
(NSData *) | - getDataWithLength: |
(NSData *) | - getData |
(id) | - getObject |
(BOOL) | - eod |
Appending Data | |
(void) | - appendByte: |
(void) | - appendUByte: |
(void) | - appendShort: |
(void) | - appendUShort: |
(void) | - appendInteger: |
(void) | - appendUInteger: |
(void) | - appendLong: |
(void) | - appendULong: |
(void) | - appendChar: |
(void) | - appendUnichar: |
(void) | - appendCharString: |
(void) | - appendBool: |
(void) | - appendFloat: |
(void) | - appendDouble: |
(void) | - appendNSInteger: |
(void) | - appendNSUInteger: |
(void) | - appendData: |
(void) | - appendObject: |
Wrapper class for data objects.
Class provides advanced methods for reading and writing information from and to data objects NSData and NSMutableData. The class is used for simplification of the implementation interaction with data objects, because standard classes does not have means for seeking within the stored data. We don't recommend to use this class directly.
- (void) appendBool: | (BOOL) | value |
Appends the specified boolean value into the receiving data.
value | - the appended value |
- (void) appendByte: | (SCByte) | value |
Appends the specified signed 8-bit integer value into the receiving data.
value | - the appended value |
- (void) appendChar: | (char) | value |
Appends the specified character into the receiving data.
value | - the appended character |
- (void) appendCharString: | (const char *) | string |
Appends the specified character string into the receiving data.
string | - the appended character string |
- (void) appendData: | (NSData *) | data |
Appends the data from the specified data object.
data | - the data object |
- (void) appendDouble: | (SCDouble) | value |
Appends the specified double value into the receiving data.
value | - the appended value |
- (void) appendFloat: | (SCFloat) | value |
Appends the specified float value into the receiving data.
value | - the appended value |
- (void) appendInteger: | (SCInteger) | value |
Appends the specified signed 32-bit integer value into the receiving data.
value | - the appended value |
- (void) appendLong: | (SCLong) | value |
Appends the specified signed 64-bit integer value into the receiving data.
value | - the appended value |
- (void) appendNSInteger: | (NSInteger) | value |
Appends the specified NSInteger value into the receiving data.
value | - the appended value |
- (void) appendNSUInteger: | (NSUInteger) | value |
Appends the specified NSUInteger value into the receiving data.
value | - the appended value |
- (void) appendObject: | (id<SCDating>) | object |
Appends the specified class instance into the receiving data.
object | - the appended object |
- (void) appendShort: | (SCShort) | value |
Appends the specified signed 16-bit integer value into the receiving data.
value | - the appended value |
- (void) appendUByte: | (SCUByte) | value |
Appends the specified unsigned 8-bit integer value into the receiving data.
value | - the appended value |
- (void) appendUInteger: | (SCUInteger) | value |
Appends the specified unsigned 32-bit integer value into the receiving data.
value | - the appended value |
- (void) appendULong: | (SCULong) | value |
Appends the specified unsigned 64-bit integer value into the receiving data.
value | - the appended value |
- (void) appendUnichar: | (unichar) | value |
Appends the specified character into the receiving data.
value | - the appended character |
- (void) appendUShort: | (SCUShort) | value |
Appends the specified unsigned 16-bit integer value into the receiving data.
value | - the appended value |
+ (instancetype) dataWithData: | (NSData *) | data |
Returns a class instance created by using the specified data object.
data | - the data object |
- (BOOL) eod |
Returns a boolean value that indicates whether the current offset is pointed to the end of the receiving data.
- (BOOL) getBool |
Returns the boolean value from the receiving data at the current offset.
- (SCByte) getByte |
Returns the signed 8-bit integer value from the receiving data at the current offset.
- (void) getBytes: | (void *) | buffer | |
length: | (NSUInteger) | length | |
Copies a number of bytes from the current offset of the receiving data into a given buffer.
buffer | - the buffer into which to copy data |
length | - the number of bytes from the current offset of the receiving data to copy to buffer |
- (char) getChar |
Returns the character from the receiving data at the current offset.
- (const char *) getCharString |
Returns the character string from the receiving data at the current offset.
- (NSData *) getData |
Returns the data object from the receiving wrapper.
- (NSData *) getDataWithLength: | (SCSize) | length |
Returns a data of the specified length from the receiving data since the current offset.
length | - the number of required bytes |
- (SCDouble) getDouble |
Returns the double value from the receiving data at the current offset.
- (SCFloat) getFloat |
Returns the float value from the receiving data at the current offset.
- (SCInteger) getInteger |
Returns the signed 32-bit integer value from the receiving data at the current offset.
- (SCLong) getLong |
Returns the signed 64-bit integer value from the receiving data at the current offset.
- (NSInteger) getNSInteger |
Returns the NSInteger value from the receiving data at the current offset.
- (NSUInteger) getNSUInteger |
Returns the NSUInteger value from the receiving data at the current offset.
- (id) getObject |
Returns the class instance from the receiving data since the current offset.
- (SCShort) getShort |
Returns the signed 16-bit integer value from the receiving data at the current offset.
- (SCUByte) getUByte |
Returns the unsigned 8-bit integer value from the receiving data at the current offset.
- (SCUInteger) getUInteger |
Returns the unsigned 32-bit integer value from the receiving data at the current offset.
- (SCULong) getULong |
Returns the unsigned 64-bit integer value from the receiving data at the current offset.
- (unichar) getUnichar |
Returns the character from the receiving data at the current offset.
- (SCUShort) getUShort |
Returns the unsigned 16-bit integer value from the receiving data at the current offset.
- (instancetype) initWithData: | (NSData *) | data |
Initializes a class instance using the specified data object.
data | - the data object |
Reimplemented from SCObject.