ViewPump 1.0.3

dotnet add package ViewPump --version 1.0.3                
NuGet\Install-Package ViewPump -Version 1.0.3                
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="ViewPump" Version="1.0.3" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add ViewPump --version 1.0.3                
#r "nuget: ViewPump, 1.0.3"                
#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.
// Install ViewPump as a Cake Addin
#addin nuget:?package=ViewPump&version=1.0.3

// Install ViewPump as a Cake Tool
#tool nuget:?package=ViewPump&version=1.0.3                

License: Apache GitHub forks

ViewPump

ViewPump allows you to intercept the view inflation process. This library allows you to customize views on an app-wide scale without having to create sub-classes (although these are supported), both before and after the view itself has been inflated.

Heavily based on InflationX' ViewPump.

Getting Started

Install ViewPump from NuGet, or add a reference to ViewPump.

At the entry point for your app, call ViewPump.InterceptingService.Init(...). You can optionally provide your own IInterceptingService implementation.

Intercepting

The view inflation process can be intercepted with two methods:

Events

IInterceptingService provides two events: InflateRequested, and ViewInflated.

InflateRequested is triggered before a view is inflated, and ViewInflated is triggered after a view has been inflated. Both events provide custom event arguments that give you relevant information per the event. See Events.

IInterceptingDelegate

You can optionally provide an IInterceptingDelegate implementation by doing the following:

ViewPump.InterceptingService.Delegate = new MyCustomInterceptingDelegate();

The delegate gives you methods that provide you with the same information as the aforementioned events. The key difference, though, is that IInterceptingDelegate.OnInflateRequested returns a bool. This allows you to deny the inflation of particular views however, there may be side effects as a result of doing so.

Android sample project

Product Compatible and additional computed target framework versions.
MonoAndroid monoandroid10.0 is compatible. 
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 ViewPump:

Package Downloads
DialogMessaging

A customizable, cross platform, dialog messaging service for Xamarin.Android and Xamarin.iOS.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.0.3 531 1/10/2022
1.0.2 435 1/10/2022
1.0.2-alpha-b55c5b5 162 1/10/2022
1.0.1 343 10/15/2021
1.0.0 331 9/7/2021
0.99.0-alpha 211 4/30/2021
0.1.0 360 3/4/2021