Soenneker.Extensions.Spans.ReadOnly.Strings 4.0.33

Prefix Reserved
dotnet add package Soenneker.Extensions.Spans.ReadOnly.Strings --version 4.0.33
                    
NuGet\Install-Package Soenneker.Extensions.Spans.ReadOnly.Strings -Version 4.0.33
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Soenneker.Extensions.Spans.ReadOnly.Strings" Version="4.0.33" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Soenneker.Extensions.Spans.ReadOnly.Strings" Version="4.0.33" />
                    
Directory.Packages.props
<PackageReference Include="Soenneker.Extensions.Spans.ReadOnly.Strings" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Soenneker.Extensions.Spans.ReadOnly.Strings --version 4.0.33
                    
#r "nuget: Soenneker.Extensions.Spans.ReadOnly.Strings, 4.0.33"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Soenneker.Extensions.Spans.ReadOnly.Strings@4.0.33
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Soenneker.Extensions.Spans.ReadOnly.Strings&version=4.0.33
                    
Install as a Cake Addin
#tool nuget:?package=Soenneker.Extensions.Spans.ReadOnly.Strings&version=4.0.33
                    
Install as a Cake Tool

alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image

alternate text is missing from this package README image Soenneker.Extensions.Spans.ReadOnly.Strings

Extension methods for searching, joining, and otherwise processing read-only spans of strings without first materializing another collection.

Installation

dotnet add package Soenneker.Extensions.Spans.ReadOnly.Strings

Usage

using Soenneker.Extensions.Spans.ReadOnly.Strings;

ReadOnlySpan<string> values = ["alpha", "Beta", "gamma"];
bool found = ReadOnlySpanStringExtension.ContainsAPart(values, "bet", StringComparison.OrdinalIgnoreCase); // true

ReadOnlySpan<string?> pieces = ["one", null, "three"];
string joined = ReadOnlySpanStringExtension.JoinStrings(pieces, ',', includeSpace: true);
// "one, , three"

ContainsAPart() skips null elements, stops at the first match, and uses exactly the supplied StringComparison.

JoinStrings() uses a pooled builder. Separators are position-based: a null element contributes no text but still leaves its separator position, as the example shows. An empty span returns ""; includeSpace adds one space after every separator.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on Soenneker.Extensions.Spans.ReadOnly.Strings:

Package Downloads
Soenneker.Extensions.Enumerable.String

A collection of helpful enumerable string extension methods

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
4.0.33 11,253 8/31/2026
4.0.32 3,444 8/30/2026
4.0.31 4,685 8/30/2026
4.0.30 83 8/29/2026
4.0.28 85 8/29/2026
4.0.27 82,959 7/28/2026
4.0.26 1,307 7/28/2026
4.0.25 21,604 7/16/2026
4.0.24 109 7/16/2026
4.0.23 30,054 6/19/2026
4.0.22 131 6/19/2026
4.0.21 29,653 6/5/2026
4.0.20 39,225 4/23/2026
4.0.19 2,716 4/22/2026
4.0.18 43,663 3/15/2026
4.0.17 6,975 3/12/2026
4.0.16 259 3/12/2026
4.0.15 137 3/12/2026
4.0.14 754 3/12/2026
4.0.13 12,199 3/11/2026
Loading failed

Update dependency Soenneker.Utils.PooledStringBuilders to 4.0.29 (#183)