IVSoftware.Portable.Common
1.1.1
Prefix Reserved
dotnet add package IVSoftware.Portable.Common --version 1.1.1
NuGet\Install-Package IVSoftware.Portable.Common -Version 1.1.1
<PackageReference Include="IVSoftware.Portable.Common" Version="1.1.1" />
<PackageVersion Include="IVSoftware.Portable.Common" Version="1.1.1" />
<PackageReference Include="IVSoftware.Portable.Common" />
paket add IVSoftware.Portable.Common --version 1.1.1
#r "nuget: IVSoftware.Portable.Common, 1.1.1"
#:package IVSoftware.Portable.Common@1.1.1
#addin nuget:?package=IVSoftware.Portable.Common&version=1.1.1
#tool nuget:?package=IVSoftware.Portable.Common&version=1.1.1
IVSoftware.Portable.Common GitHub
A small foundational library that provides shared exception-signaling primitives and metadata attributes for the IVSoftware ecosystem. It supports higher-level packages by supplying a consistent, observable way to surface errors, advisories, and diagnostics without requiring Debug builds.
A core purpose of this package is to let Release-mode NuGet packages expose services similar to System.Diagnostics (e.g., logging, tracing, caller identification, advisory messages) through a controlled signaling channel, without shipping alternate Debug variants.
Exception Signaling Model
All signaling flows through a common Throw event.
This allows end-user developers (EUDs) to log, intercept, suppress, or escalate conditions according to their own policies, even when consuming a Release-mode package.
ThrowOrAdvise
An enum representing the intent of the signal:
- ThrowHard - Standard failure path. Throws unless explicitly suppressed.
- ThrowSoft - Non-fatal condition. Never throws unless escalated.
- ThrowFramework - Framework-side fault, defaulting to throw but downgradeable.
- Advisory - Informational. Never affects control flow.
Supporting enums (ThrowableStatus, ThrowToStringFormat) describe post-raise conditions and how a Throw object formats itself.
ThrowExtensions
Extension methods that raise errors or advisories in a structured, observable way:
ThrowHard<T>()ThrowSoft<T>()ThrowFramework<T>()RethrowHard(...),RethrowSoft(...),RethrowFramework(...)Advisory(...)
Each call:
- Captures the caller identity.
- Wraps the exception in a
Throwobject that includes an ID, message, andHandledflag. - Routes the signal through a static event.
- Honors the caller's choice to suppress or escalate.
- Behaves the same whether running under Debug or Release.
This enables Release-mode diagnostics without relying on Debug.WriteLine availability or a Debug-only NuGet variant.
Advisory
A lightweight subclass of Throw representing informational messages.
Advisories use the same event channel as faults but are always non-throwing and default to diagnostic output if unhandled.
Attributes
The package includes attribute types used across IVSoftware packages:
CanonicalAttributeCarefulAttributeProbationaryAttributeScaffoldingAttributeUnsupportedAttributeIndexerAttribute
These carry intent and documentation value without enforcing runtime behavior.
Extensions
ToStrongNamedFriendAssembly(...) generates a copy-ready
InternalsVisibleTo declaration for the assembly associated with an
instance.
It is intended for source-authoring workflows where a caller needs the full
strong-name public key text for a friend assembly declaration. If called on a
Type instance, or on an assembly that is not strong-named, it returns a
policy-violation message instead.
Type Cache
TypeCache provides a lightweight reflection index over the types currently
visible in the AppDomain. It is useful when a package needs to discover or
match types by name without taking a hard project reference.
This is especially helpful for optional lateral integrations, where one assembly may want to recognize a domain type from another assembly only when that assembly is already present.
Core pieces:
Common.TypeCacheexposes the current cache as anITypeCache.GetAppDomainTypes(...)queries the cache using a match pattern.AppendNamespaceToCache(...)adds namespace-prefixed types from already loaded assemblies and records that namespace for futureAssemblyLoadevents.
Important behavior:
GetAppDomainTypes(...)defaults toTypeCacheMatchMode.NamespaceStartsWith.- If you are looking for a type by name, choose an explicit mode such as
TypeFullNameExactorTypeFullNameEndsWith. AppendNamespaceToCache(...)does not load assemblies by itself. It only indexes assemblies that are already loaded into the current AppDomain, plus any later assemblies that raiseAssemblyLoad.
Typical usage:
"IVSoftware.Portable.Collections.Events"
.AppendNamespaceToCache();
var typeChanging =
"IVSoftware.Portable.Collections.Events.NotifyCollectionChangingEventArgs"
.GetAppDomainTypes(TypeCacheMatchMode.TypeFullNameExact)
.Single();
That pattern allows a caller to perform inheritance-aware matching against a known runtime type without introducing a compile-time reference.
Purpose
IVSoftware.Portable.Common is intentionally minimal.
Its role is to provide the shared vocabulary needed for consistent behavior across multiple NuGet packages:
- Unified exception and advisory signaling in Release builds,
- Predictable logging and diagnostics without Debug-specific assemblies,
- Lightweight annotations for conveying API intent.
It serves as infrastructure for other IVSoftware packages rather than a framework layer of its own.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. 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. |
| .NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
| .NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
| MonoAndroid | monoandroid was computed. |
| MonoMac | monomac was computed. |
| MonoTouch | monotouch was computed. |
| Tizen | tizen40 was computed. tizen60 was computed. |
| Xamarin.iOS | xamarinios was computed. |
| Xamarin.Mac | xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.0
- No dependencies.
-
net8.0
- No dependencies.
NuGet packages (4)
Showing the top 4 NuGet packages that depend on IVSoftware.Portable.Common:
| Package | Downloads |
|---|---|
|
IVSoftware.Portable.WatchdogTimer
A lightweight, restartable debounce timer for .NET designed for deterministic settlement in UI and event-driven workflows. Cancellation is treated as a normal control path (no TaskCanceledException), and epochs are awaitable for structured async coordination. |
|
|
IVSoftware.Portable.Disposable.AuthorityEpochProvider
Authority-based coordination over DisposableHost epochs. Provides IAuthorityEpochProvider abstractions for deterministic ownership, ordered participation, and controlled FinalDispose behavior across concurrent consumers. |
|
|
IVSoftware.GlyphProvider.Portable
Portable glyph identity resolver using embedded config.json files shipped alongside custom fonts. Provides ToGlyph extensions, enum prototype generation, and GlyphAttribute for declarative binding. |
|
|
IVSoftware.GlyphProvider.WinForms
Windows-specific font loader and glyph support for IVSoftware’s Portable GlyphProvider. Provides PrivateFontCollection integration, embedded TTF loading, and GDI+ FontFamily materialization. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.1.1 | 179 | 5/28/2026 |
| 1.0.1 | 525 | 4/10/2026 |
| 1.0.0-rc1 | 396 | 2/6/2026 |
| 1.0.0-beta | 1,084 | 12/2/2025 |
1.1.x
- Added enum-driven policy throwing with PolicyAttribute,
PolicyEnforcementAttribute, and ThrowPolicyException.
- Added PolicyError to Throw so consumers can pattern match on
the originating enum member.
- Added PublishedContractAttribute, NotFlagsAttribute, and
ClaimAttribute.
- Added Win32Message and ToStrongNamedFriendAssembly(this object).
- Added AppDomain TypeCache baseline functionality.