Core/Misc: Misc Fixes

This commit is contained in:
hondacrx
2018-05-22 00:43:21 -04:00
parent 5dacd669b5
commit 0be2dc08e2
19 changed files with 72 additions and 115 deletions
+12 -1
View File
@@ -32,11 +32,17 @@ namespace Framework.Collections
public StringArray(string str, params string[] separator)
{
if (str.IsEmpty())
return;
_str = str.Split(separator, StringSplitOptions.RemoveEmptyEntries);
}
public StringArray(string str, params char[] separator)
{
if (str.IsEmpty())
return;
_str = str.Split(separator, StringSplitOptions.RemoveEmptyEntries);
}
@@ -51,7 +57,12 @@ namespace Framework.Collections
return _str.GetEnumerator();
}
public int Length { get { return _str.Length; } }
public bool IsEmpty()
{
return _str == null || _str.Length == 0;
}
public int Length => _str.Length;
string[] _str;
}