})} },System.Nullable{System.TimeSpan})} },System.IObservable{--1})} },System.IObservable{--1},System.Nullable{System.TimeSpan})} },ReactiveUI.Reactive.AutoPersistHelperMixins.AutoPersistMetadata)} },ReactiveUI.Reactive.AutoPersistHelperMixins.AutoPersistMetadata,System.Nullable{System.TimeSpan})} },System.IObservable{--1},ReactiveUI.Reactive.AutoPersistHelperMixins.AutoPersistMetadata)} },System.IObservable{--1},ReactiveUI.Reactive.AutoPersistHelperMixins.AutoPersistMetadata,System.Nullable{System.TimeSpan})}
AutoPersistHelperMixins.AutoPersist(T, Func>) method¶
Defined in
Type: AutoPersistHelperMixins
Namespace: ReactiveUI.Reactive
Assembly: ReactiveUI.Reactive.dll
Applies to
net10.0, net10.0-maccatalyst26.0, net10.0-desktop1.0, net10.0-browserwasm1.0, net10.0-tvos26.0, net10.0-windows10.0.19041, net10.0-macos26.0, net10.0-ios26.0, net10.0-android36.0, net9.0, net9.0-tvos18.0, net9.0-macos15.0, net9.0-maccatalyst18.0, net9.0-windows10.0.19041, net9.0-ios18.0, net9.0-desktop1.0, net8.0, net8.0-windows10.0.19041, net8.0-ios18.0, net8.0-maccatalyst18.0, net8.0-macos15.0, net8.0-tvos18.0, net8.0-ios17.5, net8.0-maccatalyst17.5, net8.0-macos14.5, netstandard2.1, net481, net462, net471
Overloads¶
- 1.
public static IDisposable AutoPersist<T>(this T @this, Func<T, IObservable<Unit>> doPersist) where T : notnull, IReactiveObject - 2.
public static IDisposable AutoPersist<T>(this T @this, Func<T, IObservable<Unit>> doPersist, TimeSpan? interval) where T : notnull, IReactiveObject - 3.
public static IDisposable AutoPersist<T, TDontCare>(this T @this, Func<T, IObservable<Unit>> doPersist, IObservable<TDontCare> manualSaveSignal) where T : notnull, IReactiveObject where TDontCare : notnull - 4.
public static IDisposable AutoPersist<T, TDontCare>(this T @this, Func<T, IObservable<Unit>> doPersist, IObservable<TDontCare> manualSaveSignal, TimeSpan? interval) where T : notnull, IReactiveObject where TDontCare : notnull - 5.
public static IDisposable AutoPersist<T>(this T @this, Func<T, IObservable<Unit>> doPersist, AutoPersistHelperMixins.AutoPersistMetadata metadata) where T : notnull, IReactiveObject - 6.
public static IDisposable AutoPersist<T>(this T @this, Func<T, IObservable<Unit>> doPersist, AutoPersistHelperMixins.AutoPersistMetadata metadata, TimeSpan? interval) where T : notnull, IReactiveObject - 7.
public static IDisposable AutoPersist<T, TDontCare>(this T @this, Func<T, IObservable<Unit>> doPersist, IObservable<TDontCare> manualSaveSignal, AutoPersistHelperMixins.AutoPersistMetadata metadata) where T : notnull, IReactiveObject where TDontCare : notnull - 8.
public static IDisposable AutoPersist<T, TDontCare>(this T @this, Func<T, IObservable<Unit>> doPersist, IObservable<TDontCare> manualSaveSignal, AutoPersistHelperMixins.AutoPersistMetadata metadata, TimeSpan? interval) where T : notnull, IReactiveObject where TDontCare : notnull
1. Overload¶
Attributes: [RequiresUnreferencedCode("AutoPersist may reflect over the runtime type; prefer the AutoPersistMetadata overloads for trimming/AOT.")] [RequiresDynamicCode("AutoPersist may reflect over the runtime type; prefer the AutoPersistMetadata overloads for trimming/AOT.")]
public static IDisposable AutoPersist<T>(this T @this, Func<T, IObservable<Unit>> doPersist) where T : notnull, IReactiveObject
Type parameters
| Name | Description |
|---|---|
T | -- |
Parameters
| Name | Type | Description |
|---|---|---|
this | T | -- |
doPersist | Func | -- |
Returns: IDisposable
2. Overload¶
Attributes: [RequiresUnreferencedCode("AutoPersist may reflect over the runtime type when it differs from T. In trimmed/AOT builds, required property/attribute metadata may be removed unless explicitly preserved. Prefer the overloads that accept AutoPersistMetadata to avoid runtime reflection.")] [RequiresDynamicCode("AutoPersist may reflect over the runtime type when it differs from T. In trimmed/AOT builds, required property/attribute metadata may be removed unless explicitly preserved. Prefer the overloads that accept AutoPersistMetadata to avoid runtime reflection.")]
public static IDisposable AutoPersist<T>(this T @this, Func<T, IObservable<Unit>> doPersist, TimeSpan? interval) where T : notnull, IReactiveObject
Type parameters
| Name | Description |
|---|---|
T | -- |
Parameters
| Name | Type | Description |
|---|---|---|
this | T | -- |
doPersist | Func | -- |
interval | TimeSpan? | -- |
Returns: IDisposable
3. Overload¶
Attributes: [RequiresUnreferencedCode("AutoPersist may reflect over the runtime type; prefer the AutoPersistMetadata overloads for trimming/AOT.")] [RequiresDynamicCode("AutoPersist may reflect over the runtime type; prefer the AutoPersistMetadata overloads for trimming/AOT.")]
public static IDisposable AutoPersist<T, TDontCare>(this T @this, Func<T, IObservable<Unit>> doPersist, IObservable<TDontCare> manualSaveSignal) where T : notnull, IReactiveObject where TDontCare : notnull
Type parameters
| Name | Description |
|---|---|
T | -- |
TDontCare | -- |
Parameters
| Name | Type | Description |
|---|---|---|
this | T | -- |
doPersist | Func | -- |
manualSaveSignal | IObservable | -- |
Returns: IDisposable
4. Overload¶
Attributes: [RequiresUnreferencedCode("AutoPersist may reflect over the runtime type when it differs from T. In trimmed/AOT builds, required property/attribute metadata may be removed unless explicitly preserved. Prefer the overloads that accept AutoPersistMetadata to avoid runtime reflection.")] [RequiresDynamicCode("AutoPersist may reflect over the runtime type when it differs from T. In trimmed/AOT builds, required property/attribute metadata may be removed unless explicitly preserved. Prefer the overloads that accept AutoPersistMetadata to avoid runtime reflection.")]
public static IDisposable AutoPersist<T, TDontCare>(this T @this, Func<T, IObservable<Unit>> doPersist, IObservable<TDontCare> manualSaveSignal, TimeSpan? interval) where T : notnull, IReactiveObject where TDontCare : notnull
Type parameters
| Name | Description |
|---|---|
T | -- |
TDontCare | -- |
Parameters
| Name | Type | Description |
|---|---|---|
this | T | -- |
doPersist | Func | -- |
manualSaveSignal | IObservable | -- |
interval | TimeSpan? | -- |
Returns: IDisposable
5. Overload¶
public static IDisposable AutoPersist<T>(this T @this, Func<T, IObservable<Unit>> doPersist, AutoPersistHelperMixins.AutoPersistMetadata metadata) where T : notnull, IReactiveObject
Type parameters
| Name | Description |
|---|---|
T | -- |
Parameters
| Name | Type | Description |
|---|---|---|
this | T | -- |
doPersist | Func | -- |
metadata | [AutoPersistMetadata](# | -- |
Returns: IDisposable
6. Overload¶
public static IDisposable AutoPersist<T>(this T @this, Func<T, IObservable<Unit>> doPersist, AutoPersistHelperMixins.AutoPersistMetadata metadata, TimeSpan? interval) where T : notnull, IReactiveObject
Type parameters
| Name | Description |
|---|---|
T | -- |
Parameters
| Name | Type | Description |
|---|---|---|
this | T | -- |
doPersist | Func | -- |
metadata | [AutoPersistMetadata](# | -- |
interval | TimeSpan? | -- |
Returns: IDisposable
7. Overload¶
public static IDisposable AutoPersist<T, TDontCare>(this T @this, Func<T, IObservable<Unit>> doPersist, IObservable<TDontCare> manualSaveSignal, AutoPersistHelperMixins.AutoPersistMetadata metadata) where T : notnull, IReactiveObject where TDontCare : notnull
Type parameters
| Name | Description |
|---|---|
T | -- |
TDontCare | -- |
Parameters
| Name | Type | Description |
|---|---|---|
this | T | -- |
doPersist | Func | -- |
manualSaveSignal | IObservable | -- |
metadata | [AutoPersistMetadata](# | -- |
Returns: IDisposable
8. Overload¶
public static IDisposable AutoPersist<T, TDontCare>(this T @this, Func<T, IObservable<Unit>> doPersist, IObservable<TDontCare> manualSaveSignal, AutoPersistHelperMixins.AutoPersistMetadata metadata, TimeSpan? interval) where T : notnull, IReactiveObject where TDontCare : notnull
Type parameters
| Name | Description |
|---|---|
T | -- |
TDontCare | -- |
Parameters
| Name | Type | Description |
|---|---|---|
this | T | -- |
doPersist | Func | -- |
manualSaveSignal | IObservable | -- |
metadata | [AutoPersistMetadata](# | -- |
interval | TimeSpan? | -- |
Returns: IDisposable