Samond Classes Library 1.2.0-RELEASE build 166
List of all members
NSString(SCString) Category Reference

Class NSString extentions category. More...

#import <SCString.h>

Inheritance diagram for NSString(SCString):
<SCCoding> <SCDictionaring> <SCStreaming> <SCCollectioning>

Creating Strings

(NSString *) + stringWithIndexSet:
 
(NSString *) + stringWithCharacter:
 
(NSString *) + stringWithCharacter:length:
 
(NSString *) + stringWithLength:
 
(NSString *) + stringWithPointer:
 
(NSString *) + stringWithID:
 

Initializing Strings

(id) - initWithIndexSet:
 
(id) - initWithCharacter:
 
(id) - initWithCharacter:length:
 
(id) - initWithLength:
 
(id) - initWithPointer:
 
(id) - initWithID:
 

Serialized Files Support

(NSString *) + stringWithCoder:
 
(NSString *) + stringWithContentsOfSerializedFile:
 
(id) - initWithContentsOfSerializedFile:
 
(BOOL) - writeContentsToSerializedFile:
 

Data Dictionaries Support

(NSString *) + stringWithDataDictionary:
 
(NSString *) + stringWithDataDictionaryFromFile:
 
(id) - initWithDataDictionary:
 
(id) - initWithDataDictionaryFromFile:
 
(void) - writeToDataDictionary:
 
(void) - writeToDataDictionaryFile:atomically:
 
(void) - writeToDataDictionaryFile:
 
(NSDictionary *) - dataDictionary
 

Streams Support

(NSString *) + stringWithStream:
 
(NSString *) + stringWithFileStream:
 
(id) - initWithStream:
 
(id) - initWithFileStream:
 
(void) - writeToStream:
 
(void) - writeToFileStream:
 
(void) - appendToFileStream:
 

Collections Support

(id< SCCollectioning >) - copyObject
 
(SCComparisonResult- compareWithObject:
 

Dividing Strings and Replacing Substrings

(NSString *) - ltrim
 
(NSString *) - rtrim
 
(NSString *) - trim
 
(NSString *) - stringWithLeftCharacters:
 
(NSString *) - stringWithRightCharacters:
 
(NSString *) - skipLeftPart:
 
(NSString *) - skipRightPart:
 
(BOOL) - isCorrectRange:
 
(BOOL) - existsSubstring:caseInsensitive:
 
(BOOL) - existsSubstring:
 
(SCUInteger- countOfSubstring:caseInsensitive:
 
(SCUInteger- countOfSubstring:
 
(NSString *) - stringWithDeletedSubstring:caseInsensitive:
 
(NSString *) - stringWithDeletedSubstring:
 
(NSString *) - stringWithDeletedSubstringToIndex:
 
(NSString *) - stringWithDeletedSubstringToRange:
 
(NSString *) - stringWithDeletedSubstringFromIndex:
 
(NSString *) - stringWithDeletedSubstringWithRange:
 
(SCUInteger- indexOfSubstring:caseInsensitive:
 
(SCUInteger- indexOfSubstring:
 
(SCArray *) - indexesOfSubstring:caseInsensitive:
 
(SCArray *) - indexesOfSubstring:
 
(NSString *) - stringWithReplacedSubstringToIndex:withString:
 
(NSString *) - stringWithReplacedSubstringFromIndex:withString:
 
(NSString *) - stringWithReplacedSubstringWithRange:withString:
 
(NSString *) - stringWithReplacedSubstring:withString:caseInsensitive:
 
(NSString *) - stringWithReplacedSubstring:withString:
 
(NSString *) - stringWithInsertedString:
 
(NSString *) - stringWithInsertedString:index:
 

String Words

NSString * normalizedString
 
SCUInteger wordsCount
 
NSString * firstWord
 
NSString * lastWord
 
NSString * endOfString
 
(NSString *) - word:
 

Comparing Strings

(BOOL) - isEqualToStrings:
 

Expanding Strings

(NSString *) + stringWithLeftExpandedString:length:character:
 
(NSString *) + stringWithLeftExpandedString:length:
 
(NSString *) + stringWithLeftZeroExpandedString:length:
 
(NSString *) + stringWithRightExpandedString:length:character:
 
(NSString *) + stringWithRightExpandedString:length:
 
(NSString *) - leftExpandedStringToLength:character:
 
(NSString *) - leftExpandedStringToLength:
 
(NSString *) - leftZeroExpandedStringToLength:
 
(NSString *) - rightExpandedStringToLength:character:
 
(NSString *) - rightExpandedStringToLength:
 
(id) - initWithLeftExpandedString:length:character:
 
(id) - initWithLeftExpandedString:length:
 
(id) - initWithLeftZeroExpandedString:length:
 
(id) - initWithRightExpandedString:length:character:
 
(id) - initWithRightExpandedString:length:
 

Adding Delimiters

(NSString *) + stringWithString:separator:left:
 
(NSString *) + stringWithString:spacesLeft:
 
(NSString *) + stringWithString:separator:right:
 
(NSString *) + stringWithString:spacesRight:
 
(NSString *) - stringWithSeparator:left:
 
(NSString *) - stringWithSpacesLeft:
 
(NSString *) - stringWithSeparator:right:
 
(NSString *) - stringWithSpacesRight:
 
(id) - initWithString:separator:left:
 
(id) - initWithString:spacesLeft:
 
(id) - initWithString:separator:right:
 
(id) - initWithString:spacesRight:
 

Data Types Representation

SCULong binaryValue
 
SCULong octalValue
 
SCULong decimalValue
 
SCULong hexadecimalValue
 
BOOL booleanValue
 
(NSString *) + stringWithBinaryInteger:capacity:
 
(NSString *) + stringWithBinaryInteger:
 
(NSString *) + stringWithOctalInteger:
 
(NSString *) + stringWithDecimalInteger:separators:
 
(NSString *) + stringWithDecimalInteger:
 
(NSString *) + stringWithInteger:
 
(NSString *) + stringWithHexadecimalInteger:capacity:
 
(NSString *) + stringWithHexadecimalInteger:
 
(NSString *) + stringWithBool:
 
(NSString *) + stringWithFloat:
 
(NSString *) + stringWithDouble:
 
(BOOL) - isBinaryString
 
(BOOL) - isOctalString
 
(BOOL) - isDecimalString
 
(BOOL) - isHexadecimalString
 
(BOOL) - isBooleanString
 
(BOOL) - isFloatString
 
(BOOL) - isDoubleString
 
(id) - initWithBinaryInteger:capacity:
 
(id) - initWithBinaryInteger:
 
(id) - initWithOctalInteger:
 
(id) - initWithDecimalInteger:separators:
 
(id) - initWithDecimalInteger:
 
(id) - initWithInteger:
 
(id) - initWithHexadecimalInteger:capacity:
 
(id) - initWithHexadecimalInteger:
 
(id) - initWithBool:
 
(id) - initWithFloat:
 
(id) - initWithDouble:
 

Reversing Strings

NSString * reversedString
 
(NSString *) + stringWithReversedString:
 
(id) - initWithReversedString:
 

Other Methods

BOOL empty
 
(NSString *) - stringWithUpperFirstLetter
 

Additional Inherited Members

- Instance Methods inherited from <SCCoding>
- Instance Methods inherited from <SCDictionaring>
- Instance Methods inherited from <SCCollectioning>

Detailed Description

Class NSString extentions category.

Since
version 1.0.0

Extends the functionality of the standard class NSString by adding the functions for string processing and library support (data dictionaries, collections, streams).

Method Documentation

- (void) appendToFileStream: (NSString *)  path

Appends the receiving string to the file stream with the specified path.

Parameters
path- the path to the destination file path
Exceptions
SCStreamException- stream error detected
SCSystemException- system error detected

Reimplemented from <SCStreaming>.

- (SCComparisonResult) compareWithObject: (id<SCCollectioning>)  object

Returns the result of comparison the receiving string with a given another string.

Parameters
object- the second instance for comparison
Returns
Comparison result:
  • SCComparisonEqual - strings are equal
  • SCComparisonLess - the receiving string is less than the specified string
  • SCComparisonGreater - the receiving string is greater than the specified string
  • SCComparisonNotAllowed - instances cannot be compared

Reimplemented from <SCCollectioning>.

- (id< SCCollectioning >) copyObject

Returns the copy of the receiving string.

Returns
A copy of the receiving string

Reimplemented from <SCCollectioning>.

- (SCUInteger) countOfSubstring: (NSString *)  substring

Returns a number of occurrences the specified substring into the receiving substring by using the the case sensitive comparison operations.

Parameters
substring- the required substring
Returns
A number of occurrences a given substring
See also
- countOfSubstring:caseInsensitive:
- (SCUInteger) countOfSubstring: (NSString *)  substring
caseInsensitive: (BOOL)  caseInsensitive 

Returns a number of occurrences the specified substring into the receiving substring by using the specified case insensitive flag.

Parameters
substring- the required substring
caseInsensitive- YES for case insensitive comparison operations, otherwise NO
Returns
A number of occurrecnes the specified substring
See also
- countOfSubstring:
- (NSDictionary *) dataDictionary

Returns the dictionary with the receiving string.

Returns
A dictionary which contains the receiving string

Reimplemented from <SCDictionaring>.

- (BOOL) existsSubstring: (NSString *)  substring

Returns a boolean value that indicates whether the receiving string is contains the specified substring by using the case sensitive comparison operations.

Parameters
substring- the required substring
Returns
YES if the specified substring is present in the receiving string, otherwise NO
See also
- existsSubstring:caseInsensitive:
- (BOOL) existsSubstring: (NSString *)  substring
caseInsensitive: (BOOL)  caseInsensitive 

Returns a boolean value that indicates whether the receiving string is contains the specified substring by using the specified case insensitive flag.

Parameters
substring- the required substring
caseInsensitive- YES for case insensitive comparison operations, otherwise NO
Returns
YES if the specified substring is present in the receiving string, otherwise NO
See also
- existsSubstring:
- (SCArray *) indexesOfSubstring: (NSString *)  substring

Returns an array with indexes of all occurrences a given substring into the receiving string by using the case sensitive comparison operations.

Parameters
substring- the desired substring
Returns
An array with indexes
See also
- indexesOfSubstring:caseInsensitive:
- (SCArray *) indexesOfSubstring: (NSString *)  substring
caseInsensitive: (BOOL)  caseInsensitive 

Returns an array with indexes of all occurrences a given substring into the receiving string by using the specified case insensitive flag.

Parameters
substring- the desired substring
caseInsensitive- YES for case insensitive comparison operations, otherwise NO
Returns
An array with indexes
See also
- indexesOfSubstring:
- (SCUInteger) indexOfSubstring: (NSString *)  substring

Returns the index of the first occurrence a given substring into the receiving substring by using the case sensitive comparison operations.

Parameters
substring- the desired substring
Returns
An index of the first occurrense of a given substring or SCNotFound if the substring does not found
See also
- indexOfSubstring:caseInsensitive:
- (SCUInteger) indexOfSubstring: (NSString *)  substring
caseInsensitive: (BOOL)  caseInsensitive 

Returns the index of the first occurence a given substring into the receiving substring by using the specified case insensitive flag.

Parameters
substring- the desired substring
caseInsensitive- YES for case insensitive comparison operations, otherwise NO
Returns
An index of the first occurrense of a given substring or SCNotFound if the substring does not found
See also
- indexOfSubstring:
- (id) initWithBinaryInteger: (SCULong integer

Initializes a string using a binary representation of the specified 32-bit integer value.

Parameters
integer- the source integer value
Returns
A newly initialized string
See also
- initWithBinaryInteger:capacity:
- (id) initWithBinaryInteger: (SCULong integer
capacity: (SCCapacity capacity 

Initializes a string using a binary representation of the specified integer value and a given capacity.

Parameters
integer- the source integer value
capacity- the capacity of the integer value:
  • SCByteCapacity - 8-bit integer value
  • SCWordCapacity - 16-bit integer value
  • SCIntCapacity - 32-bit integer value
  • SCLongCapacity - 64-bit integer value
Returns
A newly initialized string
See also
- initWithBinaryInteger:
- (id) initWithBool: (BOOL)  boolean

Initializes a string using a representation of the specified boolean value.

Parameters
boolean- the source boolean value
Returns
A newly initialized string
- (id) initWithCharacter: (unichar)  character

Initializes a string by using the specified character.

Parameters
character- the source character
Returns
A newly initialized string
- (id) initWithCharacter: (unichar)  character
length: (SCUInteger length 

Initializes a string by using the specified number of a given character.

Parameters
character- the source character
length- the number of the characters
Returns
A newly initialized string
- (id) initWithContentsOfSerializedFile: (NSString *)  path

Initializes a string by using the data from the serialized file with the specified path.

Parameters
path- the path of the serialzed file
Returns
A newly initialized string

Reimplemented from <SCCoding>.

- (id) initWithDataDictionary: (NSDictionary *)  dictionary

Initializes a string by using the data from the specified data dictionary.

Parameters
dictionary- the source data dictionary
Returns
A newly initialized string

Reimplemented from <SCDictionaring>.

- (id) initWithDataDictionaryFromFile: (NSString *)  path

Initializes a string by using the data from the dictionary file with the specified path.

Parameters
path- the path to the source dictionary file
Returns
A newly initialized string

Reimplemented from <SCDictionaring>.

- (id) initWithDecimalInteger: (SCLong integer

Initializes a string using a decimal representation of the specified integer value.

Parameters
integer- the source integer value
Returns
A newly initialized string
See also
- initWithDecimalInteger:separators:
- initWithInteger:
- (id) initWithDecimalInteger: (SCLong integer
separators: (BOOL)  separators 

Initializes a string using a decimal representation of the specified integer value and flag of using the digit group delimiters.

Parameters
integer- the source integer value
separators- YES for using digit group delimiters and NO for initializing string without digit group delimiters
Returns
A newly initialized string
See also
- initWithDecimalInteger:
- initWithInteger:
- (id) initWithDouble: (SCDouble value

Initializes a string using a representation of the specified double value.

Parameters
value- the source double value
Returns
A newly initialized string
- (id) initWithFileStream: (NSString *)  path

Initializes a string by using the data from the file stream with the specified path.

Parameters
path- the path to the source file stream
Returns
A newly initialized string
Exceptions
SCStreamException- stream error detected
SCSystemException- system error detected

Reimplemented from <SCStreaming>.

- (id) initWithFloat: (SCFloat value

Initializes a string using a representation of the specified float value.

Parameters
value- the source float value
Returns
A newly initialized string
- (id) initWithHexadecimalInteger: (SCULong integer

Initializes a string using a hexadecimal representation of the specified integer value.

Parameters
integer- the source integer value
Returns
A newly initialized string
See also
- initWithHexadecimalInteger:capacity:
- (id) initWithHexadecimalInteger: (SCULong integer
capacity: (SCCapacity capacity 

Initializes a string using a hexadecimal representation of the specified integer value and a given capacity.

Parameters
integer- the source integer value
capacity- the capacity of the integer value:
  • SCByteCapacity - 8-bit integer value
  • SCWordCapacity - 16-bit integer value
  • SCIntCapacity - 32-bit integer value
  • SCLongCapacity - 64-bit integer value
Returns
A newly initialized string
See also
- initWithHexadecimalInteger:
- (id) initWithID: (id)  object

Initializes a string by using the specified class instance.

Parameters
object- the source class instance
Returns
A newly initialized string
- (id) initWithIndexSet: (NSIndexSet *)  indexSet

Initializes a string by using the specified index set.

Parameters
indexSet- the source index set
Returns
A newly initialized string
- (id) initWithInteger: (SCLong integer

Initializes a string using a decimal representation of the specified integer value.

Parameters
integer- the source integer value
Returns
A newly initialized string
See also
- initWithDecimalInteger:separators:
- initWithDecimalInteger:
- (id) initWithLeftExpandedString: (NSString *)  string
length: (SCUInteger length 

Initializes a string by padding the specified source string on the left with the spaces to a given length.

Parameters
string- the source string
length- the required length of the initialized string
Returns
A newly initialized string
- (id) initWithLeftExpandedString: (NSString *)  string
length: (SCUInteger length
character: (unichar)  character 

Initializes a string by padding the specified source string on the left with the specified character to a given length.

Parameters
string- the source string
length- the required length of the initialized string
character- the character to padding
Returns
A newly initialized string
- (id) initWithLeftZeroExpandedString: (NSString *)  string
length: (SCUInteger length 

Initializes a string by padding the specified source string on the left with the zero characters to a given length.

Parameters
string- the source string
length- the required length of the initialized string
Returns
A newly initialized string
- (id) initWithLength: (SCUInteger length

Initializes a string by using the specified number of the space characters.

Parameters
length- the length of the new string
Returns
A newly initialized string
- (id) initWithOctalInteger: (SCULong integer

Initializes a string using an octal representation of the specified integer value.

Parameters
integer- the source integer value
Returns
A newly initialized string
- (id) initWithPointer: (void *)  pointer

Initializes a string by using the specified pointer.

Parameters
pointer- the source pointer
Returns
A newly initialized string
- (id) initWithReversedString: (NSString *)  string

Initializes a string using the characters from a given string in the reversed order.

Parameters
string- the source string
Returns
A newly initialized string
- (id) initWithRightExpandedString: (NSString *)  string
length: (SCUInteger length 

Initializes a string by padding the specified source string on the right with the spaces to a given length.

Parameters
string- the source string
length- the reqyuired length of the initialized string
Returns
A newly initialized string
- (id) initWithRightExpandedString: (NSString *)  string
length: (SCUInteger length
character: (unichar)  character 

Initializes a string by padding the specified source string on the right with the specified character to a given length.

Parameters
string- the source string
length- the required length of the initialized string
character- the character to padding
Returns
A newly initialized string
- (id) initWithStream: (SCStream *)  stream

Initializes a string by using the data from the specified stream.

Parameters
stream- the source stream
Returns
A newly initialized string
Exceptions
SCStreamException- stream error detected
SCSystemException- system error detected

Reimplemented from <SCStreaming>.

- (id) initWithString: (NSString *)  string
separator: (NSString *)  separator
left: (SCUInteger left 

Initializes a string by adding a given group separators after the specified number of characters from left to right of the specified source string.

Parameters
string- the source string
separator- the separator to add into the initialized string
left- the number of characters within the each group
Returns
A newly initialized string
- (id) initWithString: (NSString *)  string
separator: (NSString *)  separator
right: (SCUInteger right 

Initializes a string by adding a given group separators after the specified number of characters from right to left of the specified source string.

Parameters
string- the source string
separator- the separator to add into the initialized string
right- the number of characters within the each group
Returns
A newly initialized string
- (id) initWithString: (NSString *)  string
spacesLeft: (SCUInteger left 

Initializes a string by adding the spaces as a group separators after the specified number of characters from left to right of the specified source string.

Parameters
string- the source string
left- the number of characters within the each group
Returns
A newly initialized string
- (id) initWithString: (NSString *)  string
spacesRight: (SCUInteger right 

Initializes a string by adding the spaces as a group separators after the specified number of characters from right to left of the specified source string.

Parameters
string- the source string
right- the number of characters within the each group
Returns
A newly initialized string
- (BOOL) isBinaryString

Returns a boolean value that determines whether the receiving string is a binary representation of the integer value.

Returns
YES if the receiving string is a binary representation of the integer value, otherwise NO
- (BOOL) isBooleanString

Returns a boolean value that determines whether the receiving string is a boolean value representation.

Returns
YES if the receiving string is a boolean value representation, otherwise NO
- (BOOL) isCorrectRange: (NSRange)  range

Returns a boolean value that indicates whether the specified characters range is correct within the receiving string.

Parameters
range- the characters range to check
Returns
YES if the specified range is correct, otherwise NO
- (BOOL) isDecimalString

Returns a boolean value that determines whether the receiving string is a decimal representation of the integer value.

Returns
YES if the receiving string is a decimal representation of the integer value, otherwise NO
- (BOOL) isDoubleString

Returns a boolean value that determines whether the receiving string is a representation of the double floating-point value.

Returns
YES if the receiving string is a representation of the double value, otherwise NO
- (BOOL) isEqualToStrings: (NSString *)  string
,   NS_REQUIRES_NIL_TERMINATION 

Returns a boolean value that indicates whether the receiving string is equal to any string from a given string list.

Parameters
string- the first string to compare with the receiving string
...- a null-terminated list of alternating strings to compare
NS_REQUIRES_NIL_TERMINATION- the mandatory nil pointer
Returns
YES if the receiving string is equal to any string within the list, otherwise NO
- (BOOL) isFloatString

Returns a boolean value that determines whether the receiving string is a representation of the float floating-point value.

Returns
YES if the receiving string is a representation of the float value, otherwise NO
- (BOOL) isHexadecimalString

Returns a boolean value that determines whether the receiving string is a hexadecimal representation of the integer value.

Returns
YES if the receiving string is a hexadecimal representation of the integer value, otherwise NO
- (BOOL) isOctalString

Returns a boolean value that determines whether the receiving string is an octal representation of the integer value.

Returns
YES if the receiving string is an octal representation of the integer value, otherwise NO
- (NSString *) leftExpandedStringToLength: (SCUInteger length

Returns a receiving string padded on the left by the spaces to the specified length.

Parameters
length- the required string length
Returns
A padded string
- (NSString *) leftExpandedStringToLength: (SCUInteger length
character: (unichar)  character 

Returns a receiving string padded on the left of the specified character to the specified length.

Parameters
length- the required string length
character- the padding character
Returns
A padded string
- (NSString *) leftZeroExpandedStringToLength: (SCUInteger length

Returns a receiving string padded on the left by the zero characters to the specified length.

Parameters
length- the required string length
Returns
A padded string
- (NSString *) ltrim

Returns the receiving string without the leading spaces and tabs.

Returns
A string without the leading spaces and tabs.
- (NSString *) rightExpandedStringToLength: (SCUInteger length

Returns a receiving string padded on the right by the spaces to the specified length.

Parameters
length- the required length of the string
Returns
A padded string
- (NSString *) rightExpandedStringToLength: (SCUInteger length
character: (unichar)  character 

Returns a receiving string padded on the right by the specified character to the specified length.

Parameters
length- the required string length
character- the padding character
Returns
A padded string
- (NSString *) rtrim

Returns the receiving string without the trailing spaces and tabs.

Returns
A string without the trailing spaces and tabs.
- (NSString *) skipLeftPart: (SCUInteger characters

Returns a receiving string without the specified number of the leading characters.

Parameters
characters- the number of the characters to remove
Returns
A string without the removed characters
- (NSString *) skipRightPart: (SCUInteger characters

Returns a string without the specified number of the trailing characters.

Parameters
characters- the number of the characters to remove
Returns
A string without the removed characters
+ (NSString *) stringWithBinaryInteger: (SCULong integer

Returns a string created by using a binary representation of the specified 32-bit integer value.

Parameters
integer- the source integer value
Returns
A created string
See also
+ stringWithBinaryInteger:capacity:
+ (NSString *) stringWithBinaryInteger: (SCULong integer
capacity: (SCCapacity capacity 

Returns a string created by using a binary representation of the specified integer value and a given capacity:

Parameters
integer- the source integer value
capacity- the capacity of the integer value:
  • SCByteCapacity - 8-bit integer value
  • SCWordCapacity - 16-bit integer value
  • SCIntCapacity - 32-bit integer value
  • SCLongCapacity - 64-bit integer value
Returns
A created string
See also
+ stringWithBinaryInteger:
+ (NSString *) stringWithBool: (BOOL)  boolean

Returns a string created by using a representation of the specified boolean value.

Parameters
boolean- the source boolean value
Returns
A created string
+ (NSString *) stringWithCharacter: (unichar)  character

Returns a string created by using the specfied character.

Parameters
character- the source character
Returns
A created string
+ (NSString *) stringWithCharacter: (unichar)  character
length: (SCUInteger length 

Returns a string created by using the specified character and a length of the new string.

Parameters
character- the source character
length- the length of the new string
Returns
A created string
+ (NSString *) stringWithCoder: (NSCoder *)  coder

Returns a string created by using the data from the specified coder.

Parameters
coder- the source coder
Returns
A created string
+ (NSString *) stringWithContentsOfSerializedFile: (NSString *)  path

Returns a string created by using the data from the serialized file with the specified path.

Parameters
path- the path of the serialized file
Returns
A created string
+ (NSString *) stringWithDataDictionary: (NSDictionary *)  dictionary

Returns a string created by using the data from the specified data dictionary.

Parameters
dictionary- the source data dictionary
Returns
A created string
+ (NSString *) stringWithDataDictionaryFromFile: (NSString *)  path

Returns a string created by using the data from the dictionary file with the specified path.

Parameters
path- the path to the source dictionary file
Returns
A created string
+ (NSString *) stringWithDecimalInteger: (SCLong integer

Returns a string created by using a decimal representation of the specified integer value.

Parameters
integer- the source integer value
Returns
A created string
See also
+ stringWithDecimalInteger:separators:
+ stringWithInteger:
+ (NSString *) stringWithDecimalInteger: (SCLong integer
separators: (BOOL)  separators 

Returns a string created by using a decimal representation of the specified integer value and a flag of using the digit group delimiters.

Parameters
integer- the source integer value
separators- YES for using the digit group delimiters and NO for creating string without digit group delimiters
Returns
A created string
See also
+ stringWithDecimalInteger:
+ stringWithInteger:
- (NSString *) stringWithDeletedSubstring: (NSString *)  substring

Returns the receiving string without a given substring by using the case sensitive comparison operations.

Parameters
substring- the substring to remove
Returns
A string without the specified substring
See also
- stringWithDeletedSubstring:caseInsensitive:
- (NSString *) stringWithDeletedSubstring: (NSString *)  substring
caseInsensitive: (BOOL)  caseInsensitive 

Returns the receiving string without a given substring by using the specified case insensitive flag.

Parameters
substring- the substring to remove
caseInsensitive- YES for case insensitive comparison operations, otherwise NO
Returns
A string without the specified substring
See also
- stringWithDeletedSubstring:
- (NSString *) stringWithDeletedSubstringFromIndex: (SCUInteger index

Returns the receiving string without characters after the specified index.

Parameters
index- the index of the first character to remove
Returns
A string without characters
- (NSString *) stringWithDeletedSubstringToIndex: (SCUInteger index

Returns the receiving string without the characters before a given index.

Parameters
index- the index of the last removed character
Returns
A string without characters
- (NSString *) stringWithDeletedSubstringToRange: (NSRange)  range

Returns the receiving string with characters after a given range.

Parameters
range- the range of the characters
Returns
A string without characters
- (NSString *) stringWithDeletedSubstringWithRange: (NSRange)  range

Returns the receiving string without characters within the specified range.

Parameters
range- the range of characters to remove
Returns
A string without characters
+ (NSString *) stringWithDouble: (SCDouble value

Return a string created by using a representation of the specified double value.

Parameters
value- the source double value
Returns
A created string
+ (NSString *) stringWithFileStream: (NSString *)  path

Returns a string created by using the data from the file stream with the specified path.

Parameters
path- the path to the source file stream
Returns
A created string
Exceptions
SCStreamException- stream error detected
SCSystemException- system error detected
+ (NSString *) stringWithFloat: (SCFloat value

Returns a string created by using a representation of the specified float value.

Parameters
value- the source float value
Returns
A created string
+ (NSString *) stringWithHexadecimalInteger: (SCULong integer

Returns a string created by using a hexadecimal representation of the specified integer value.

Parameters
integer- the source integer value
Returns
A created string
See also
+ stringWithHexadecimalInteger:capacity:
+ (NSString *) stringWithHexadecimalInteger: (SCULong integer
capacity: (SCCapacity capacity 

Returns a string created by using a hexadecimal representation of the specified integer value and a given capacity.

Parameters
integer- the source integer value
capacity- the capacity of the integer value:
  • SCByteCapacity - 8-bit integer value
  • SCWordCapacity - 16-bit integer value
+ (NSString *) stringWithID: (id)  object

Returns a string created by using the specified object.

Parameters
object- the source object
Returns
A created string
+ (NSString *) stringWithIndexSet: (NSIndexSet *)  indexSet

Returns a string created by using the specified index set.

Parameters
indexSet- the source index set
Returns
A created string
- (NSString *) stringWithInsertedString: (NSString *)  string

Returns the receiving string with a given substring before the first character.

Parameters
string- the substring to insert
Returns
A string with the substring
- (NSString *) stringWithInsertedString: (NSString *)  string
index: (SCUInteger index 

Inserts the specified substring at a given index and returns the new string.

Parameters
string- the substring to insert
index- the index to the inserting a substring
Returns
A string with the substring
+ (NSString *) stringWithInteger: (SCLong integer

Returns a string created by using a decimal representation of the specified integer value.

Parameters
integer- the source integer value
Returns
A created string
See also
+ stringWithDecimalInteger:separators:
+ stringWithDecimalInteger:
- (NSString *) stringWithLeftCharacters: (SCUInteger characters

Returns a string with the specified number of the leading characters from the receiving string.

Parameters
characters- the number of the leading characters
Returns
A string with the specified number of the leading characters
+ (NSString *) stringWithLeftExpandedString: (NSString *)  string
length: (SCUInteger length 

Returns a string created by padding the specified source string on the left with the spaces to a given length.

Parameters
string- the source string
length- the required length of the new string
Returns
A created string
+ (NSString *) stringWithLeftExpandedString: (NSString *)  string
length: (SCUInteger length
character: (unichar)  character 

Returns a string created by padding the specified source string on the left with the specified character to a given length.

Parameters
string- the source string
length- the required length of the new string
character- the character to padding
Returns
A created string
+ (NSString *) stringWithLeftZeroExpandedString: (NSString *)  string
length: (SCUInteger length 

Returns a string created by padding the specified source string on the left with the zero characters to a given length.

Parameters
string- the source string
length- the required length of the new string
Returns
A created string
+ (NSString *) stringWithLength: (SCUInteger length

Returns a string created by using the specified number of the space characters.

Parameters
length- the length of the new string
Returns
A created string
+ (NSString *) stringWithOctalInteger: (SCULong integer

Returns a string created by using an octal representation of the specified integer value.

Parameters
integer- the source integer value
Returns
A created string
+ (NSString *) stringWithPointer: (void *)  pointer

Returns a string created by using the specified pointer.

Parameters
pointer- the source pointer
Returns
A created string
- (NSString *) stringWithReplacedSubstring: (NSString *)  substring
withString: (NSString *)  string 

Returns the receiving string in which all occurrences of the specified substring are replaced by using an another given string.

Parameters
substring- the substring to replace
string- the new substring
Returns
A string with the replaced substring
See also
stringWithReplaceSubstring:withString:caseInsensitive:
- (NSString *) stringWithReplacedSubstring: (NSString *)  substring
withString: (NSString *)  string
caseInsensitive: (BOOL)  caseInsensitive 

Returns the receiving string in which all occurrences of the specified substring are replaced by using an another given string.@ Additional flag defines the case sensitive mode.

Parameters
substring- the substring to replace
string- the new substring
caseInsensitive- YES for the case insensitive mode and NO for the case sensitive comparison operations
Returns
A string with the replaced substring
See also
stringWithReplacedSubstring:withSubstring:
- (NSString *) stringWithReplacedSubstringFromIndex: (SCUInteger index
withString: (NSString *)  string 

Returns the receiving string with the specified number of the trailing characters is replaced by a given substring.

Parameters
index- the index of the first character to replace
string- the substring with which will be replaced the specified characters
Returns
A string with the replaced characters
- (NSString *) stringWithReplacedSubstringToIndex: (SCUInteger index
withString: (NSString *)  string 

Returns the receiving string with the specified number of the leading characters is replaced by a given substring.
If the specified substring is empty, then returns the receiving string without the characters before the specified index.

Parameters
index- the index of the last character to replace
string- the substring with which will be replaced the specified characters
Returns
A string with the replaced characters
- (NSString *) stringWithReplacedSubstringWithRange: (NSRange)  range
withString: (NSString *)  string 

Returns the receiving string with the characters within a given range are replaced by the specified substring.

Parameters
range- the range of the characters to replace
string- the substring with which will be replaced the specified characters
Returns
A string with the replaced characters
+ (NSString *) stringWithReversedString: (NSString *)  string

Returns a string created by using the characters from a given string in the reversed order.

Parameters
string- the source string
Returns
A created string
- (NSString *) stringWithRightCharacters: (SCUInteger characters

Returns a string with the specified number of the trailing characters from the receiving string.

Parameters
characters- the number of the trailing characters
Returns
A string with the specified number of the trailing characters
+ (NSString *) stringWithRightExpandedString: (NSString *)  string
length: (SCUInteger length 

Returns a string created by padding the specified source string on the right with the spaces to a given length.

Parameters
string- the source string
length- the required length of the new string
Returns
A created string
+ (NSString *) stringWithRightExpandedString: (NSString *)  string
length: (SCUInteger length
character: (unichar)  character 

Returns a string created by padding the specified source string on the right with the specified character to a given length.

Parameters
string- the source string
length- the required length of the new string
character- the character to padding
Returns
A created string
- (NSString *) stringWithSeparator: (NSString *)  separator
left: (SCUInteger left 

Returns a string with the added given group separators after the specified number of characters from the left to right of the receiving string.

Parameters
separator- the separator to add into the receiving string
left- the number of the characters within the each group
Returns
A string with the group separators
- (NSString *) stringWithSeparator: (NSString *)  separator
right: (SCUInteger right 

Returns a string with the added given group separators after the specified number of characters from right to left of the receiving string.

Parameters
separator- the separator to add into the receiving string
right- the number of the characters within the each group
Returns
A string with the group separators
- (NSString *) stringWithSpacesLeft: (SCUInteger left

Returns a string with the added spaces as a group separators after the specified number of character from the left to right of the receiving string.

Parameters
left- the number of the characters within the each group
Returns
A string with the group separators
- (NSString *) stringWithSpacesRight: (SCUInteger right

Returns a string with the added spaces as a group separators after the specified number of characters from the left to right of the receiving string.

Parameters
right- the number of the characters within the each group
Returns
A string with the group separators
+ (NSString *) stringWithStream: (SCStream *)  stream

Returns a string created by using the data from the specified stream.

Parameters
stream- the source stream
Returns
A created string
Exceptions
SCStreamException- stream error detected
SCSystemException- system error detected
+ (NSString *) stringWithString: (NSString *)  string
separator: (NSString *)  separator
left: (SCUInteger left 

Returns a string created by adding a given group separators after the specified number of characters from left to right of the specified source string.

Parameters
string- the source string
separator- the separator to add into the created string
left- the number of the characters within the each griup
Returns
A created string
+ (NSString *) stringWithString: (NSString *)  string
separator: (NSString *)  separator
right: (SCUInteger right 

Returns a string created by adding a given group separators after the specified number of characters from right to left of the specified source string.

Parameters
string- the source string
separator- the separator to add into the created string
right- the number of the characters within the each group
Returns
A created string
+ (NSString *) stringWithString: (NSString *)  string
spacesLeft: (SCUInteger left 

Returns a string created by adding the spaces as a group separators after the specified number of characters from left to right of the specified source string.

Parameters
string- the source string
left- the number of the characters within the each group
Returns
A created string
+ (NSString *) stringWithString: (NSString *)  string
spacesRight: (SCUInteger right 

Returns a string created by adding the spaces as a group separators after the specified number of characters from right to left of the specified source string.

Parameters
string- the source string
right- the number of the characters within the each group
Returns
A created string
- (NSString *) stringWithUpperFirstLetter

Returns a string with the first character in uppercase and other characters in lowercase.

Returns
A string with the first uppercase character
- (NSString *) trim

Returns the receiving string without leading and trailing spaces and tabs.

Returns
A string without leading and trailing spaces and tabs
- (NSString *) word: (SCUInteger word

Returns the word of the receiving string at the specified index.

Parameters
word- the index of the word
Returns
The word at a given index of empty string if the index is incorrect
- (BOOL) writeContentsToSerializedFile: (NSString *)  path

Writes the receiving string to the serialized file with the specified path.

Parameters
path- the path to the serialized file
Returns
YES if the operation is successfully, otherwise NO

Reimplemented from <SCCoding>.

- (void) writeToDataDictionary: (NSMutableDictionary *)  dictionary

Writes the receiving string into the specified data dictionary.

Parameters
dictionary- the dictionary to store the receiving string

Reimplemented from <SCDictionaring>.

- (void) writeToDataDictionaryFile: (NSString *)  path

Writes the receiving string into the data dictionary file with the specified path.

Parameters
path- the path to the data dictionary file

Reimplemented from <SCDictionaring>.

- (void) writeToDataDictionaryFile: (NSString *)  path
atomically: (BOOL)  atomically 

Writes the receiving string into the data dictionary file with the specified path.

Parameters
path- the path to the data dictionary file
atomically- YES for using the intermediate file and NO for direct writing operation

Reimplemented from <SCDictionaring>.

- (void) writeToFileStream: (NSString *)  path

Writes the receiving string to the file stream with the specified path.

Parameters
path- the path to the destination file stream
Exceptions
SCStreamException- stream error detected
SCSystemException- system error detected

Reimplemented from <SCStreaming>.

- (void) writeToStream: (SCStream *)  stream

Writes the receiving string to the specified stream.

Parameters
stream- the destination stream
Exceptions
SCStreamException- stream error detected
SCSystemException- system error detected

Reimplemented from <SCStreaming>.

Property Documentation

- (SCULong) binaryValue
readnonatomicassign

The integer value of the binary integer string

- (BOOL) booleanValue
readnonatomicassign

The boolean value of the string

- (SCULong) decimalValue
readnonatomicassign

The integer value of the decimal integer string

- (BOOL) empty
readnonatomicassign

The boolean value that detrmines whether the string is contains at least one character

- (NSString *) endOfString
readnonatomicretain

String without the first word

- (NSString *) firstWord
readnonatomicretain

First word of the receiving string

- (SCULong) hexadecimalValue
readnonatomicassign

The integer value of the hexadecimal integer string

- (NSString *) lastWord
readnonatomicretain

Last word of the receiving string

- (NSString *) normalizedString
readnonatomicretain

Normilized string

- (SCULong) octalValue
readnonatomicassign

The integer value of the octal integer string

- (NSString *) reversedString
readnonatomicretain

The string with the reversed order of the characters

- (SCUInteger) wordsCount
readnonatomicassign

Number of words within the receiving string


The documentation for this category was generated from the following files: