Class SafeStringCollection
- Namespace
- SunamoCollectionsGeneric.Collections
- Assembly
- SunamoCollectionsGeneric.dll
A string collection that replaces unallowed characters with a safe replacement character
public class SafeStringCollection
- Inheritance
-
SafeStringCollection
- Inherited Members
- Extension Methods
Constructors
SafeStringCollection(List<char>, char)
Initializes a new instance with characters to replace and the replacement character
public SafeStringCollection(List<char> unallowedChars, char replacementCharacter)
Parameters
unallowedCharsList<char>List of characters that are not allowed
replacementCharactercharThe character to replace unallowed characters with
Properties
Items
Gets or sets the list of sanitized string items
public List<string> Items { get; set; }
Property Value
Methods
Add(string)
Adds a string to the collection after replacing all unallowed characters
public void Add(string text)
Parameters
textstringThe text to add