mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-19 16:40:26 +02:00
Working on BeefInstall
This commit is contained in:
parent
15e65e240d
commit
3515a59bea
9 changed files with 450 additions and 43 deletions
|
@ -1685,22 +1685,22 @@ namespace System
|
|||
return EqualsHelper(a.Ptr, b.Ptr, a.mLength);
|
||||
}
|
||||
|
||||
public bool StartsWith(String b, StringComparison comparisonType = StringComparison.Ordinal)
|
||||
public bool StartsWith(StringView b, StringComparison comparisonType = StringComparison.Ordinal)
|
||||
{
|
||||
if (mLength < b.mLength)
|
||||
if (mLength < b.[Friend]mLength)
|
||||
return false;
|
||||
if (comparisonType == StringComparison.OrdinalIgnoreCase)
|
||||
return EqualsIgnoreCaseHelper(this.Ptr, b.Ptr, b.Length);
|
||||
return EqualsHelper(this.Ptr, b.Ptr, b.mLength);
|
||||
return EqualsHelper(this.Ptr, b.Ptr, b.[Friend]mLength);
|
||||
}
|
||||
|
||||
public bool EndsWith(String b, StringComparison comparisonType = StringComparison.Ordinal)
|
||||
public bool EndsWith(StringView b, StringComparison comparisonType = StringComparison.Ordinal)
|
||||
{
|
||||
if (mLength < b.mLength)
|
||||
if (mLength < b.[Friend]mLength)
|
||||
return false;
|
||||
if (comparisonType == StringComparison.OrdinalIgnoreCase)
|
||||
return EqualsIgnoreCaseHelper(Ptr + mLength - b.mLength, b.Ptr, b.mLength);
|
||||
return EqualsHelper(this.Ptr + mLength - b.mLength, b.Ptr, b.mLength);
|
||||
return EqualsIgnoreCaseHelper(Ptr + mLength - b.[Friend]mLength, b.Ptr, b.[Friend]mLength);
|
||||
return EqualsHelper(this.Ptr + mLength - b.[Friend]mLength, b.Ptr, b.[Friend]mLength);
|
||||
}
|
||||
|
||||
public bool EndsWith(char8 c)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue