Samond Classes Library 1.2.6-STABLE build 219
List of all members
SCStrings Class Reference

Strings list class. More...

#import <SCStrings.h>

+ Inheritance diagram for SCStrings:

Instance Properties

NSString * name
 
SCIndex count
 
BOOL readOnly
 
BOOL empty
 
BOOL modified
 
BOOL caseInsensitive
 
id< SCTextDelegatedelegate
 

Creating Strings Lists

(instancetype) + stringsWithCoder:
 
(instancetype) + stringsWithContentsOfSerializedFile:
 
(instancetype) + stringsWithDataDictionary:
 
(instancetype) + stringsWithDataDictionaryFromFile:
 
(instancetype) + stringsWithStream:
 
(instancetype) + stringsWithFileStream:
 
(instancetype) + stringsWithData:
 
(instancetype) + stringsWithContentsOfFile:
 
(instancetype) + stringsWithContentsOfURL:
 
(instancetype) + stringsWithContentsOfURLString:
 
(instancetype) + stringsWithName:
 
(instancetype) + stringsWithString:
 
(instancetype) + stringsWithCollection:
 
(instancetype) + stringsWithArray:
 
(instancetype) + stringsWithStrings:
 
(instancetype) + strings
 

Initializing Strings Lists

(instancetype) - initWithName:
 
(instancetype) - initWithString:
 
(instancetype) - initWithCollection:
 
(instancetype) - initWithArray:
 
(instancetype) - initWithStrings:
 
(instancetype) - init
 

Copying Strings Lists

(void) - setStrings:
 
(void) - setCollection:
 
(void) - setString:
 

Comparing Strings Lists

(BOOL) - isEqualToStrings:
 
(BOOL) - isEqualToCollection:
 
(BOOL) - isEqualTo:
 
(BOOL) - isEqual:
 

Deriving New Strings Lists

(instancetype) - stringsByAddingString:
 
(instancetype) - stringsByAddingCollection:
 
(instancetype) - stringsByAddingStrings:
 
(instancetype) - stringsByAddingStringsFromArray:
 
(instancetype) - stringsByAddingArray:
 

Strings Enumerators

NSEnumerator * stringEnumerator
 
NSEnumerator * reverseStringEnumerator
 
(void) - enumerateWithDelegate:
 
(void) - enumerate
 
(void) - reverseEnumerateWithDelegate:
 
(void) - reverseEnumerate
 
(NSUInteger) - countByEnumeratingWithState:objects:count:
 

Converting Strings Lists

SCArrayarray
 
NSArray * foundationArray
 

Sorting Strings Lists

SCStringsascendingSortedStrings
 
SCStringsdescendingSortedStrings
 
SCStringssortedStrings
 
(void) - sortAscendingWithSorter:
 
(void) - sortDescendingWithSorter:
 
(void) - sortWithSorter:
 
(void) - sortAscending
 
(void) - sortDescending
 
(void) - sort
 
(SCStrings *) - ascendingSortedStringsWithSorter:
 
(SCStrings *) - descendingSortedStringsWithSorter:
 
(SCStrings *) - sortedStringsWithSorter:
 

Adding Strings

(void) - addString:
 
(void) - addCollection:
 
(void) - addStrings:
 
(void) - addLine
 
(void) - addStringsFromArray:
 
(void) - addArray:
 
(void) - insertString:atIndex:
 
(void) - insertStrings:atIndex:
 
(void) - insertCollection:atIndex:
 
(void) - insertStrings:atIndexes:
 
(void) - insertCollection:atIndexes:
 
(void) - insertLineAtIndex:
 

Removing Strings

(void) - removeAllStrings
 
(void) - removeFirstString
 
(void) - removeLastString
 
(void) - removeStringAtIndex:
 
(void) - removeStringsAtIndexes:
 
(void) - removeString:
 
(void) - removeStrings:
 
(void) - removeCollection:
 
(void) - removeStringsWithSubstring:
 
(void) - removeStringsNotAtIndexes:
 
(void) - removeStringsNotEqualTo:
 
(void) - removeStringsNotInStrings:
 
(void) - removeStringsNotInCollection:
 
(void) - removeStringsWithoutSubstring:
 
(void) - removeDuplicatedStrings
 

Replacing Strings

(void) - replaceStringAtIndex:withString:
 
(void) - replaceStringsAtIndexes:withStrings:
 
(void) - replaceStringsAtIndexes:withCollection:
 
(void) - replaceString:withString:
 
(void) - setObject:atIndexedSubscript:
 

Copying and Moving Strings

SCStringsreversedStrings
 
(void) - exchangeStringAtIndex:withStringAtIndex:
 
(void) - duplicateStringAtIndex:
 
(void) - duplicateAllStrings
 
(void) - duplicate
 
(void) - copyStringAtIndex:toIndex:
 
(void) - moveStringAtIndex:toIndex:
 
(void) - forwardMoveStringAtIndex:steps:
 
(void) - forwardMoveStringAtIndex:
 
(void) - backwardMoveStringAtIndex:steps:
 
(void) - backwardMoveStringAtIndex:
 
(void) - moveToFirstPositionStringAtIndex:
 
(void) - moveToLastPositionStringAtIndex:
 
(void) - reverse
 

Querying a Strings List

NSString * firstString
 
NSString * lastString
 
(NSString *) - stringAtIndex:
 
(SCStrings *) - stringsAtIndexes:
 
(id) - objectAtIndexedSubscript:
 

Finding Strings in a Strings List

SCIndex indexOfLastString
 
(BOOL) - containsString:
 
(BOOL) - containsStrings:
 
(BOOL) - containsCollection:
 
(BOOL) - containsAnyString:
 
(BOOL) - containsAnyStringFromCollection:
 
(BOOL) - containsSubstring:
 
(BOOL) - containsSubstrings:
 
(BOOL) - containsSubstringsFromCollection:
 
(BOOL) - containsAnySubstring:
 
(BOOL) - containsAnySubstringFromCollection:
 
(BOOL) - containsDuplicatedStrings
 
(SCIndex- indexOfString:
 
(SCIndex- indexOfSubstring:
 
(SCStrings *) - stringsWithSubstring:
 
(SCStrings *) - stringsWithSubstrings:
 
(SCStrings *) - stringsWithSubstringsFromCollection:
 
(SCStrings *) - stringsWithAnySubstring:
 
(SCStrings *) - stringsWithAnySubstringFromCollection:
 
(SCStrings *) - stringsWithoutSubstring:
 
(SCStrings *) - stringsWithoutSubstrings:
 
(SCStrings *) - stringsWithoutSubstringsFromCollection:
 
(SCULong- countOfString:
 
(SCULong- countOfSubstring:
 
(SCULong- countOfStringsWithSubstring:
 

Additional Inherited Members

- Instance Methods inherited from SCObject
(instancetype) - initWithContentsOfSerializedFile:
 
(BOOL) - writeContentsToSerializedFile:
 
(instancetype) - initWithDataDictionaryFromFile:
 
(void) - writeToDataDictionaryFile:atomically:
 
(void) - writeToDataDictionaryFile:
 
(NSDictionary *) - dataDictionary
 
(instancetype) - initWithFileStream:
 
(void) - writeToFileStream:
 
(void) - appendToFileStream:
 
(instancetype) - initWithData:
 
(instancetype) - initWithContentsOfFile:
 
(instancetype) - initWithContentsOfURL:
 
(instancetype) - initWithContentsOfURLString:
 
(BOOL) - writeToFile:
 
(BOOL) - writeToURL:
 
(BOOL) - writeToURLString:
 
(NSData *) - data
 
- Properties inherited from SCObject
NSString * className
 

Detailed Description

Strings list class.

SDK
macOS 10.6+, iOS 7.0+, GNUstep
Since
version 1.1.4

Implements the strings list, which stores the strings and allows the simple strings operations. Also class is a parent class for all other text classes.
Class instances can thrown the following exceptions:

Method Documentation

- (void) addArray: (SCArray *)  array

Adds into the receiving strings list strings from a given array.

Parameters
array- an array with objects to add to the receiving strings list
Exceptions
SCTextException- text error detected
Since
version 1.2.3
See also
- addStringsFromArray:
- (void) addCollection: (id<SCCollection>)  collection

Adds into the receiving strings list the strings from the specified existing collection of any supported type.

Parameters
collection- the source collection of any supported type
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
- (void) addLine

Adds into the receiving strings list the empty string. Empty string is a string, which does not contains any characters.

Exceptions
SCTextException- text error detected
- (void) addString: (NSString *)  string

Adds into the receiving strings list the specified existing string.

Parameters
string- the string to be adding into the strings list
Exceptions
SCTextException- text error detected
- (void) addStrings: (SCStrings *)  strings

Adds into the receiving strings list the strings from the specified existing strings list.

Parameters
strings- the source strings list
Exceptions
SCTextException- text error detected
- (void) addStringsFromArray: (SCArray *)  array

Adds into the receiving strings list strings from a given array.

Parameters
array- an array with objects to add to the receiving strings list
Exceptions
SCTextException- text error detected
Since
version 1.2.3
See also
- addArray:
- (SCStrings *) ascendingSortedStringsWithSorter: (id<SCSorter>)  sorter

Returns the strings list with ascending sorted using the specified strings sorter strings from the receiving strings list.

Parameters
sorter- the strings sorter
Returns
A strings list with sorted strings
Exceptions
SCTextException- text error detected
See also
- sortedStringsWithSorter:
- (void) backwardMoveStringAtIndex: (SCIndex index

Moves the string at the specified index to an one position to the bottom of the receiving strings list.

Parameters
index- the index of the moved string
Exceptions
SCTextException- text error detected
- (void) backwardMoveStringAtIndex: (SCIndex index
steps: (SCIndex steps 

Moves the string at the specified index to a given number of positions to the bottom of the receiving strings list.

Parameters
index- the index of the moved string
steps- the number of positions
Exceptions
SCTextException- text error detected
- (BOOL) containsAnyString: (SCStrings *)  strings

Returns a boolean value that indicates whether the receiving strings list contains at least one strings from the specified strings list.

Parameters
strings- the list of the required strings
Returns
YES if at least one of given strings is present in the receiving strings list, otherwise NO
- (BOOL) containsAnyStringFromCollection: (id<SCCollection>)  collection

Returns a boolean value that indicates whether the receiving strings list contains at least one string from the specified collection of any supported type.

Parameters
collection- the source collection
Returns
YES if at least one of strings within the collection is present in the receiving strings list, otherwise NO
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
- (BOOL) containsAnySubstring: (SCStrings *)  substrings

Returns a boolean value that indicates whether the receiving strings list contains at least one substring from the specified substrings list.

Parameters
substrings- the strings list with desired substrings
Returns
YES if the receiving strings list contains at least one of the substrings from the specified strings list, otherwise NO
- (BOOL) containsAnySubstringFromCollection: (id<SCCollection>)  collection

Returns a boolean value that indicates whether the receiving strings list contains at least one substring from the specified collection of any supported type.

Parameters
collection- the collection with the desired strings
Returns
YES if the receiving strings list contains at least one of the substrings from the specified collection, otherwise NO
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
- (BOOL) containsCollection: (id<SCCollection>)  collection

Returns a boolean value that indicates whether the receiving strings list contains the all strings from the specified collection of any supported type.

Parameters
collection- the collection with the required strings
Returns
YES if all of strings from the specified collection are present in the receiving strings list, otherwise NO
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
- (BOOL) containsDuplicatedStrings

Returns a boolean value that indicates whether the receiving strings list contains at least one duplicated string.

Returns
YES if the receiving strings list contains at least one duplicated string, otherwise NO
- (BOOL) containsString: (NSString *)  string

Returns a boolean value that indicates whether a given string is present in the receiving strings list.

Parameters
string- the desired string
Returns
YES if a given string is present in the receiving strings list, otherwise NO
- (BOOL) containsStrings: (SCStrings *)  strings

Returns a boolean value that indicates whether the receiving strings list contains the all strings from the specified strings list.

Parameters
strings- the list of the required strings
Returns
YES if all of given strings are present in the receiving strings list, otherwise NO
- (BOOL) containsSubstring: (NSString *)  substring

Returns a boolean value that indicates whether the receiving strings list contains the specified substring.

Parameters
substring- the desired substring
Returns
YES if the substring presents in the receiving strings list, otherwise NO
- (BOOL) containsSubstrings: (SCStrings *)  substrings

Returns a boolean value that indicates whether the receiving strings list contains all of substrings from the specified strings list.

Parameters
substrings- the strings list with the desired substrings
Returns
YES if the receiving strings list contains all of the substrings from the specified strings list, otherwise NO
- (BOOL) containsSubstringsFromCollection: (id<SCCollection>)  collection

Returns a boolean value that indicates whether the receiving strings list contains all of substrings from the specified collection of any supported type.

Parameters
collection- the collection with the desired substrings
Returns
YES if the receiving strings list contains all of the substrings from the specified collection, otherwise NO
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
- (void) copyStringAtIndex: (SCIndex index
toIndex: (SCIndex destination 

Copies the string at the specified index to a given destination index.

Parameters
index- the source index
destination- the destination index
Exceptions
SCTextException- text error detected
- (NSUInteger) countByEnumeratingWithState: (NSFastEnumerationState *)  state
objects: (id *)  objects
count: (NSUInteger)  count 

Returns by reference a C array of objects over which the sender should iterate, and as the return value the number of objects in the array.

Parameters
state- context information that is used in the enumeration to, in addition to other possibilities, ensure that the collection has not been mutated
objects- a C array of objects over which the sender is to iterate
count- the maximum number of objects to return in a C array
Returns
The number of objects returned in a C array or 0 when the iteration is finished
Since
version 1.2.5
- (SCULong) countOfString: (NSString *)  string

Returns a count of strings from the receiving strings list which are required to the specified string.

Parameters
string- the desired string
Returns
A number of the desired strings
- (SCULong) countOfStringsWithSubstring: (NSString *)  substring

Returns a count of strings from the receiving strings list that contain at least one occurrence of the specified substring.

Parameters
substring- the requited substring
Returns
A number of strings with the desired substring
- (SCULong) countOfSubstring: (NSString *)  substring

Returns a count of occurrences the specified substring into the strings within the receiving strings list.

Parameters
substring- the desired substring
Returns
A number of accurrences of the desired substring
- (SCStrings *) descendingSortedStringsWithSorter: (id<SCSorter>)  sorter

Returns the strings list with descending sorted using the specified strings sorter strings from the receiving strings list.

Parameters
sorter- the strings sorter
Returns
A strings list with sorted strings
Exceptions
SCTextException- text error detected
- (void) duplicate

Duplicates content of the receiving strings list.

Exceptions
SCTextException- text error detected
- (void) duplicateAllStrings

Duplicates all strings within receiving strings list.

Exceptions
SCTextException- text error detected
- (void) duplicateStringAtIndex: (SCIndex index

Duplicates the string at the specified index.

Parameters
index- the index of the string to be duplicated
Exceptions
SCTextException- text error detected
- (void) enumerate

Tells the strings list delegate object for each string in the receiving strings list.

- (void) enumerateWithDelegate: (id<SCTextDelegate>)  delegate

Tells the specified delegate object for each string in the receiving strings list.

Parameters
delegate- the delegate object
- (void) exchangeStringAtIndex: (SCIndex index
withStringAtIndex: (SCIndex destination 

Exchanges the strings in the receiving strings list at a given indexes.

Parameters
index- the index of the first string
destination- the index of the second string
Exceptions
SCTextException- text error detected
- (void) forwardMoveStringAtIndex: (SCIndex index

Moves the string at the specified index to an one position to the top of the receiving strings list.

Parameters
index- the index of the moved string
Exceptions
SCTextException- text error detected
- (void) forwardMoveStringAtIndex: (SCIndex index
steps: (SCIndex steps 

Moves the string at the specified index to a given number of positions to the top of the receiving strings list.

Parameters
index- the index of the moved string
steps- the number of positions
Exceptions
SCTextException- text error detected
- (SCIndex) indexOfString: (NSString *)  string

Returns the lowest index whose corresponding strings list item is equal to a given string.

Parameters
string- the desired string
Returns
Index of item that equals to the specified string, otherwise SCNotFound
Exceptions
SCTextException- text error detected
- (SCIndex) indexOfSubstring: (NSString *)  substring

Returns the lowest index whose corresponding string contains a given substring.

Parameters
substring- the desired substring
Returns
An index of string that contains the specified substring, otherwise SCNotFound
- (instancetype) init

Initializes an empty unnamed strings list using the default settings.

Returns
A newly initialized strings list
- (instancetype) initWithArray: (SCArray *)  array

Initializes a strings list using objects from a given array.

Parameters
array- an array with strings
Returns
A newly initialized strings list
Exceptions
SCTextException- text error detected
Since
version 1.2.3
- (instancetype) initWithCollection: (id<SCCollection>)  collection

Initializes a strings list using strings from the specified existing source collection of any supported type.

Parameters
collection- the source collection of any supported type
Returns
A newly initialized strings list
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
- (instancetype) initWithName: (NSString *)  name

Initializes a strings list using the specified list name.

Attention
Designed initializer
Parameters
name- the name of the strings list
Returns
A newly initialized strings list
- (instancetype) initWithString: (NSString *)  string

Initializes a strings list using the specified existing source string.

Parameters
string- the source string
Returns
A newly initialized strings list
Exceptions
SCTextException- text error detected
- (instancetype) initWithStrings: (SCStrings *)  strings

Initializes a strings list using strings from the specified existing source strings list.

Attention
Designed initializator
Parameters
strings- the source strings list
Returns
A newly initialized strings list
Exceptions
SCTextException- text error detected
- (void) insertCollection: (id<SCCollection>)  collection
atIndex: (SCIndex index 

Inserts the strings from the specified existing collection of any supported type into the receiving strings list at a given index.

Parameters
collection- the source collection of any supported type
index- the index at which to insert strings
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
- (void) insertCollection: (id<SCCollection>)  collection
atIndexes: (NSIndexSet *)  indexes 

Inserts the strings from the specified existing collection of any supported type at the specified indexes into the receiving strings list.

Parameters
collection- the source collection of any supported type
indexes- indexes at which the strings should be inserted
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
- (void) insertLineAtIndex: (SCIndex index

Inserts into the receiving strings list empty string at the specified index.

Parameters
index- the index at which the empty line should be inserted
Exceptions
SCTextException- text error detected
- (void) insertString: (NSString *)  string
atIndex: (SCIndex index 

Inserts a given existing string into the receiving strings list at a given index.

Parameters
string- the string to be inserting into the receiving strings list
index- the index at which to insert string
Exceptions
SCTextException- text error detected
- (void) insertStrings: (SCStrings *)  strings
atIndex: (SCIndex index 

Inserts the strings from the specified existing strings list into the receiving strings list at a given index.

Parameters
strings- the list with string to be inserting into the receiving strings list
index- the index at which to insert strings
Exceptions
SCTextException- text error detected
- (void) insertStrings: (SCStrings *)  strings
atIndexes: (NSIndexSet *)  indexes 

Inserts the strings from a given existing strings list at the specified indexes into the receiving strings list.

Parameters
strings- the source strings list
indexes- indexes at which the strings should be inserted
Exceptions
SCTextException- text error detected
- (BOOL) isEqual: (id)  object

Returns a boolean value that indicates whether the content of the receiving strings list is equal to the specified object.

Parameters
object- the object with which to compare the receiving strings list
Returns
YES if the specified object is equal to the content of the receiving strings list, otherwise NO
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
See also
- isEqualTo:

Reimplemented from SCObject.

- (BOOL) isEqualTo: (id)  object

Returns a boolean value that indicates whether the content of the receiving strings list is equal to the specified object.

Parameters
object- the object with which to compare the receiving strings list
Returns
YES if the specified object is equal to the content of the receiving strings list, otherwise NO
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
See also
- isEqual:
- (BOOL) isEqualToCollection: (id<SCCollection>)  collection

Returns a boolean value that indicates whether the content of the receiving strings list is equal to the content of the specified collection of any supported type.

Parameters
collection- the collection with which to compare the receiving strings list
Returns
YES if the content of the specified collection is equal to the content of the receiving strings list, otherwise NO
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
- (BOOL) isEqualToStrings: (SCStrings *)  strings

Returns a boolean value that indicates whether the content of the receiving strings list is equal to the content of another given strings list.

Parameters
strings- the strings list with which to compare the receiving strings list
Returns
YES if the content of other strings list is equal to the content of the receiving strings list, otherwise NO
- (void) moveStringAtIndex: (SCIndex index
toIndex: (SCIndex destination 

Moves the string at the specified index to a given destination index.

Parameters
index- the index of moved string
destination- the destination index
Exceptions
SCTextException- text error detected
- (void) moveToFirstPositionStringAtIndex: (SCIndex index

Moves the string at the specified index to the first position within the receiving strings list.

Parameters
index- the index of the moved string
Exceptions
SCTextException- text error detected
- (void) moveToLastPositionStringAtIndex: (SCIndex index

Moves the string at the specified index to the last position withing the receiving strings list.

Parameters
index- the index of the moved string
Exceptions
SCTextException- text error detected
- (id) objectAtIndexedSubscript: (SCIndex index

Returns the object at the specified index.

Parameters
index- the index within the bounds of the array
Returns
The object located at a given index
Exceptions
SCTextException- text error detected
Since
version 1.2.5
- (void) removeAllStrings

Removes all strings from the receiving strings list.

Exceptions
SCTextException- text error detected
- (void) removeCollection: (id<SCCollection>)  collection

Removes from the receiving strings list the strings from the specified collection of any supported type.

Parameters
collection- the collection containing the strings to be removed from the receiving strings list
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
- (void) removeDuplicatedStrings

Removes all duplicates strings from the receiving strings list.

Exceptions
SCTextException- text error detected
- (void) removeFirstString

Removes the first string from the receiving strings list.

Exceptions
SCTextException- text error detected
- (void) removeLastString

Removes the last string from the receiving strings list.

Exceptions
SCTextException- text error detected
- (void) removeString: (NSString *)  string

Removes all occurrences in the receiving strings list of a given string.

Parameters
string- the string to remove from the strings list
Exceptions
SCTextException- text error detected
- (void) removeStringAtIndex: (SCIndex index

Removes from the receiving strings list the string at the specified index.

Parameters
index- the index from which to remove the string in the list
Exceptions
SCTextException- text error detected
- (void) removeStrings: (SCStrings *)  strings

Removes from the receiving strings list the strings from the specified strings list.

Parameters
strings- the strings list containing the strings to be removed from the receiving strings list
Exceptions
SCTextException- text error detected
- (void) removeStringsAtIndexes: (NSIndexSet *)  indexes

Removes from the receiving strings list the strings at the indexes from the specified index set.

Parameters
indexes- the indexes of the strings to remove from the list
Exceptions
SCTextException- text error detected
- (void) removeStringsNotAtIndexes: (NSIndexSet *)  indexes

Removes from the receiving strings list strings with indexes which not present in the specified index set.

Parameters
indexes- the set of indexes of keeping strings
Exceptions
SCTextException- text error detected
- (void) removeStringsNotEqualTo: (NSString *)  string

Removes from the receiving strings list all strings which not equal to the specified string.

Parameters
string- the string left in the list
Exceptions
SCTextException- text error detected
- (void) removeStringsNotInCollection: (id<SCCollection>)  collection

Removes from the receiving strings list all strings which not present in the specified collection of any supported type.

Parameters
collection- the collection with keeped strings
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
- (void) removeStringsNotInStrings: (SCStrings *)  strings

Removes from the receiving strings list all strings which not present in the specified strings list.

Parameters
strings- the list of saved lines
Exceptions
SCTextException- text error detected
- (void) removeStringsWithoutSubstring: (NSString *)  substring

Removes all occurrences in the receiving strings list of strings which not contain the specified substring.

Parameters
substring- the keeping substring
Exceptions
SCTextException- text error detected
- (void) removeStringsWithSubstring: (NSString *)  substring

Removes all occurrences in the receiving strings list of the strings which contain the specified substring.

Parameters
substring- the substring for search of removed strings
Exceptions
SCTextException- text error detected
- (void) replaceString: (NSString *)  string
withString: (NSString *)  newString 

Replaces all occurrences of the specified strings within the receiving strings list with a given string.

Parameters
string- the replaced string
newString- the replacement string
Exceptions
SCTextException- text error detected
- (void) replaceStringAtIndex: (SCIndex index
withString: (NSString *)  string 

Replaces the string at the specified index with a given string.

Parameters
index- the index of the string to be replaced
string- the string with which to replace the string at the specified index
Exceptions
SCTextException- text error detected
- (void) replaceStringsAtIndexes: (NSIndexSet *)  indexes
withCollection: (id<SCCollection>)  collection 

Replaces the strings in the receiving list at specified locations with the strings from the specified collection of any supported type.

Parameters
indexes- the indexes of strings to be replaced
collection- the collection with strings which to replace the strings in the receiving strings list
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
- (void) replaceStringsAtIndexes: (NSIndexSet *)  indexes
withStrings: (SCStrings *)  strings 

Replaces the strings in the receiving strings list at specified locations with the strings from a given strings list.

Parameters
indexes- the indexes of strings to be replaced
strings- the strings with which to replace the strings in the receiving list
Exceptions
SCTextException- text error detected
- (void) reverse

Reverses the order of all strings in the receiving strings list.

Exceptions
SCTextException- text error detected
- (void) reverseEnumerate

Tells the strings list delegate object for each string in the receiving strings list, in reverse order.

- (void) reverseEnumerateWithDelegate: (id<SCTextDelegate>)  delegate

Tells the specified delegate object for each string in the receiving strings list, in reverse order.

Parameters
delegate- the delegate object
- (void) setCollection: (id<SCCollection>)  collection

Replaces the content and settings of the receiving strings list by using the content and settings from the specified existing source collection of any supported type.

Parameters
collection- the source collection of any supported type
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
- (void) setObject: (NSString *)  object
atIndexedSubscript: (SCIndex index 

Replaces the object at the specified index with the new object, possibly adding the object.

Parameters
object- the object with which to replace object at a specified index
index- the index of the object to be replaced
Exceptions
SCTextException- text error detected
Since
version 1.2.5
- (void) setString: (NSString *)  string

Replaces the content of the receiving strings list by using the specified existing source string.

Parameters
string- the source string
Exceptions
SCTextException- text error detected
- (void) setStrings: (SCStrings *)  strings

Replaces the content and settings of the receiving strings list by using the content and settings from the specified existing source strings list.

Parameters
strings- the source strings list
Exceptions
SCTextException- text error detected
- (void) sort

Sorts ascending the receiving strings list using the defult strings sorter.

Exceptions
SCTextException- text error detected
See also
- sortAscending
- (void) sortAscending

Sorts ascending the receiving strings list using the default strings sorter.

Exceptions
SCTextException- text error detected
See also
- sort
- (void) sortAscendingWithSorter: (id<SCSorter>)  sorter

Sorts ascending the receiving strings list using the specified strings sorter.

Parameters
sorter- the strings sorter
Exceptions
SCTextException- text error detected
See also
- sortWithSorter:
- (void) sortDescending

Sorts descending the receiving strings list using the default strings sorter.

Exceptions
SCTextException- text error detected
- (void) sortDescendingWithSorter: (id<SCSorter>)  sorter

Sorts descending the receiving strings list using the specified strings sorter.

Parameters
sorter- the strings sorter
Exceptions
SCTextException- text error detected
- (SCStrings *) sortedStringsWithSorter: (id<SCSorter>)  sorter

Returns the strings list with ascending sorted using the specified strings sorter strings from the receiving strings list.

Parameters
sorter- the strings sorter
Returns
A strings list with sorted strings
Exceptions
SCTextException- text error detected
See also
- ascendingSortedStringsWithSorter:
- (void) sortWithSorter: (id<SCSorter>)  sorter

Sorts ascending the receiving strings list using the specified strings sorter.

Parameters
sorter- the strings sorter
Exceptions
SCTextException- text error detected
See also
- sortAscendingWithSorter:
- (NSString *) stringAtIndex: (SCIndex index

Returns the string located at the specified index.

Parameters
index- the index of the required string
Returns
A string at the specified index
Exceptions
SCTextException- text error detected
+ (instancetype) strings

Returns an empty unnamed strings list created by using the default settings.

Returns
A created strings list
- (SCStrings *) stringsAtIndexes: (NSIndexSet *)  indexes

Returns a strings list containing the strings in the receiving list at the indexes specified by a given index set.

Parameters
indexes- the index set with the indexes of the required strings
Returns
A strings list with the required strings
Exceptions
SCTextException- text error detected
- (instancetype) stringsByAddingArray: (SCArray *)  array

Returns the strings list that contains strings from the receiving strings list and a given array.

Parameters
array- the array with strings to add to the new strings list
Returns
A strings list with strings from the receiving strings list and a given array
Exceptions
SCTextException- text error detected
Since
version 1.2.3
See also
stringsByAaddingObjectsFromArray:
- (instancetype) stringsByAddingCollection: (id<SCCollection>)  collection

Returns the strings list that contains strings from the receiving strings list and a given collection.

Parameters
collection- the collection with strings to add to the new strings list
Returns
A strings list with strings from the receiving strings list and a given collection
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
Since
version 1.2.3
- (instancetype) stringsByAddingString: (NSString *)  string

Returns the strings list that contains strings from the receiving strings list and a given string.

Parameters
string- the string to add to the new strings list
Returns
A new strings list with strings from the receiving strings list and a specified string
Exceptions
SCTextException- text error detected
Since
version 1.2.3
- (instancetype) stringsByAddingStrings: (SCStrings *)  strings

Returns the strings list that contains strings from the receiving strings list and a given another strings list.

Parameters
strings- the list with strings to add to the new strings list
Returns
A strings list with strings from the receiving strings list and a given another strings list
Exceptions
SCTextException- text error detected
Since
version 1.2.3
- (instancetype) stringsByAddingStringsFromArray: (SCArray *)  array

Returns the strings list that contains strings from the receiving strings list and a given array.

Parameters
array- the array with strings to add to the new strings list
Returns
A strings list with strings from the receiving strings list and a given array
Exceptions
SCTextException- text error detected
Since
version 1.2.3
See also
- stringsByAddingArray:
- (SCStrings *) stringsWithAnySubstring: (SCStrings *)  substrings

Returns a list of strings that contain at least one substring from the specified list.

Parameters
substrings- the list of the desired strings
Returns
A strings list with the required strings
- (SCStrings *) stringsWithAnySubstringFromCollection: (id<SCCollection>)  collection

Returns a list of strings that contain at least one substring from the specified collection of any supported type.

Parameters
collection- the collection with desired substrings
Returns
A strings list with the required strings
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
+ (instancetype) stringsWithArray: (SCArray *)  array

Returns a strings list created by using strings from a given array.

Parameters
array- an array with strings
Returns
A created strings list
Exceptions
SCTextException- text error detected
Since
version 1.2.3
+ (instancetype) stringsWithCoder: (NSCoder *)  coder

Returns a strings list created by using the specified coder.

Parameters
coder- the source coder
Returns
A created strings list
+ (instancetype) stringsWithCollection: (id<SCCollection>)  collection

Returns a strings list created by using strings from the specified existing collection of any supported type.

Parameters
collection- the source collection of any supported type
Returns
A created strings list
Exceptions
SCTextException- text error detected
SCTextException- collection error detected
+ (instancetype) stringsWithContentsOfFile: (NSString *)  path

Returns a strings list created by using the file with the specified path.

Parameters
path- the path to the source file
Returns
A created strings list
+ (instancetype) stringsWithContentsOfSerializedFile: (NSString *)  path

Returns a strings list created by using the contents of serialized file with the specified path.

Parameters
path- the path of a source serialized file
Returns
A created strings list
+ (instancetype) stringsWithContentsOfURL: (NSURL *)  url

Returns a strings list created by using the specified URL.

Parameters
url- the source URL
Returns
A created strings list
+ (instancetype) stringsWithContentsOfURLString: (NSString *)  urlString

Returns a strings list created by using the data from the URL with the specified string.

Parameters
urlString- the string of the source URL
Returns
A created strings list
+ (instancetype) stringsWithData: (NSData *)  data

Returns a strings list created by using the specified data object.

Parameters
data- the source data object
Returns
A created strings list
+ (instancetype) stringsWithDataDictionary: (NSDictionary *)  dictionary

Returns a strings list created by using the specified data dictionary.

Parameters
dictionary- the source data dictionary
Returns
A created strings list
+ (instancetype) stringsWithDataDictionaryFromFile: (NSString *)  path

Returns a strings list created by using the data dictionary from the specified file.

Parameters
path- the path of a source data dictionary file
Returns
A created strings list
+ (instancetype) stringsWithFileStream: (NSString *)  path

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

Parameters
path- the path of a source stream file
Returns
A created strings list
Exceptions
SCStreamException- stream error detected
SCSystemException- system error detected
+ (instancetype) stringsWithName: (NSString *)  name

Returns a strings list created by using the specified list name.

Parameters
name- the name of the strings list
Returns
A created strings list
- (SCStrings *) stringsWithoutSubstring: (NSString *)  substring

Returns a list of strings that do not contain the specified substring.

Parameters
substring- the desired substring
Returns
A list of strings without specified substring
- (SCStrings *) stringsWithoutSubstrings: (SCStrings *)  substrings

Returns a list of strings that do not contain the substrings from the specified list.

Parameters
substrings- the list of the desired substrings
Returns
A list of strings without specified substrings
- (SCStrings *) stringsWithoutSubstringsFromCollection: (id<SCCollection>)  collection

Returns a list of strings that do not contain the substrings from the specified collection of any supported type.

Parameters
collection- the collection with desired substrings
Returns
A list of strings without specified substrings
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected
+ (instancetype) stringsWithStream: (SCStream *)  stream

Returns a strings list created by using the data from the specified stream.

Parameters
stream- the source stream
Returns
A created strings list
Exceptions
SCStreamException- stream error detected
SCSystemException- system error detected
+ (instancetype) stringsWithString: (NSString *)  string

Returns a strings list created by using the specified existing source string.

Parameters
string- the source string
Returns
A created strings list
Exceptions
SCTextException- text error detected
+ (instancetype) stringsWithStrings: (SCStrings *)  strings

Returns a strings list created by using strings from the specified existing source strings list.

Parameters
strings- the source strings list
Returns
A created strings list
Exceptions
SCTextException- text error detected
- (SCStrings *) stringsWithSubstring: (NSString *)  substring

Returns a list of strings that contain the specified substring.

Parameters
substring- the desired substring
Returns
A strings list with required strings
- (SCStrings *) stringsWithSubstrings: (SCStrings *)  substrings

Returns a list of strings that contain all substrings from the specified list.

Parameters
substrings- the list of the desired substrings
Returns
A strings list with required strings
- (SCStrings *) stringsWithSubstringsFromCollection: (id<SCCollection>)  collection

Returns a list of strings that contain all substrings from the specified collection of any supported type.

Parameters
collection- the collection with desired substrings
Returns
A strings list with the required strings
Exceptions
SCTextException- text error detected
SCCollectionException- collection error detected

Property Documentation

- (SCArray *) array
readnonatomicassign

Returns an array with the copy of all receving strings list strings.

- (SCStrings *) ascendingSortedStrings
readnonatomicassign

Returns the strings list with ascending sorted strings from the receiving strings list.

See also
sortedStrings
- (BOOL) caseInsensitive
readwritenonatomicassign

Determines whether the search and comparison operations are case insensitive.

- (SCIndex) count
readnonatomicassign

Returns the count of strings within the strings list.

- (id<SCTextDelegate>) delegate
readwritenonatomicretain

Contains the strings list delegate object.

- (SCStrings *) descendingSortedStrings
readnonatomicassign

Returns the strings list with descending sorted strings from the receiving strings list.

- (BOOL) empty
readnonatomicassign

Determines whether the strings list is empty or contains at least one string.

- (NSString *) firstString
readnonatomicassign

Returns the first string from the receiving strings list

- (NSArray *) foundationArray
readnonatomicretain

Returns a foundation array with the copy of all receiving strings list strings.

- (SCIndex) indexOfLastString
readnonatomicassign

Returns the index of the last string within the receiving strings list.

- (NSString *) lastString
readnonatomicassign

Returns the last string from the receivinf strings list

- (BOOL) modified
readnonatomicassign

Determines whether the receiving strings list has uncommitted changes.

- (NSString *) name
readwritenonatomicretain

Contains the text instance name.

- (BOOL) readOnly
readwritenonatomicassign

Determines whether the strings list in read only mode.

- (SCStrings *) reversedStrings
readnonatomicassign

Returns the strings list with the all strings from the receiving strings list in reverse order

- (NSEnumerator *) reverseStringEnumerator
readnonatomicassign

Returns an enumerator object that lets you access each string in the receiving strings list, in reverse order.

- (SCStrings *) sortedStrings
readnonatomicassign

Returns the strings list with ascending sorted strings from the receiving strings list.

See also
ascendingSortedStrings
- (NSEnumerator *) stringEnumerator
readnonatomicassign

Returns an enumerator object that lets you access each string in the receiving strings list.


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