Method
UrlBuilder.AddSegmentIf
AddSegmentIf(string, bool) #
Conditionally adds a segment to the URL path.
public UrlBuilder AddSegmentIf(string segment, bool condition)Parameters #
segment string
The segment to add.
condition bool
The condition under which the segment should be added.
Returns #
The current UrlBuilder instance, with the segment added if condition is true.