C# Class GenFu.Utilities.StringBuilderExtensions

Afficher le fichier Open project: MisterJames/GenFu

Méthodes publiques

Méthode Description
AppendWhen ( this sb, string value, bool predicate ) : StringBuilder

Append a string when a predicate evaluates true.

BuildFor ( this sb, int times, StringBuilder>.Func fn ) : StringBuilder

Repeats a string builder operation for n times.

BuildFor ( this sb, int times, Func fn ) : StringBuilder

Repeats a string builder operation for n times.

Method Details

AppendWhen() public static méthode

Append a string when a predicate evaluates true.
public static AppendWhen ( this sb, string value, bool predicate ) : StringBuilder
sb this
value string String to append.
predicate bool Predicate
Résultat StringBuilder

BuildFor() public static méthode

Repeats a string builder operation for n times.
public static BuildFor ( this sb, int times, StringBuilder>.Func fn ) : StringBuilder
sb this
times int Number of times to repeat.
fn StringBuilder>.Func A StringBuilder function.
Résultat StringBuilder

BuildFor() public static méthode

Repeats a string builder operation for n times.
public static BuildFor ( this sb, int times, Func fn ) : StringBuilder
sb this
times int Number of times to repeat.
fn Func A StringBuilder function with index.
Résultat StringBuilder