WALTER | Workable Algorithms for Location-aware Transmission, Encryption Response

StringExtensions..::..Substrings Method

Split a string in chunks of a given size, the last entry get's the left-overs of the string is not divisible by the chunk size

Namespace:  System
Assembly:  Walter (in Walter.dll)

Syntax


public static IEnumerable<string> Substrings(
	string str,
	int maxChunkSize
)

Parameters

str
Type: String
the string to split
maxChunkSize
Type: Int32
the size of each of the substring

Return Value

a set of substrings with a given maximum size

Remarks


A empty string or null will return a empty IEnumerable