Humanizer.ITruncator
ITruncator Interface
Can truncate a string.
public interface ITruncator
Derived
↳ DynamicNumberOfCharactersAndPreserveWordsTruncator
Methods
ITruncator.Truncate(string, int, string, TruncateFrom) Method
Truncate a string
string? Truncate(string? value, int length, string? truncationString, Humanizer.TruncateFrom truncateFrom=Humanizer.TruncateFrom.Right);
Parameters
value System.String
The string to truncate
length System.Int32
The length to truncate to
truncationString System.String
The string used to truncate with
truncateFrom TruncateFrom
The enum value used to determine from where to truncate the string
Returns
System.String
The truncated string