共用方式為


IPersistentStateFactory.Create 方法

定義

多載

Create<TState>(IGrainActivationContext, IPersistentStateConfiguration)
Create<TState>(IGrainContext, IPersistentStateConfiguration)

建立所提供之粒紋的永續性狀態實例。

Create<TState>(IGrainActivationContext, IPersistentStateConfiguration)

來源:
IPersistentStateFactory.cs
public Orleans.Runtime.IPersistentState<TState> Create<TState> (Orleans.Runtime.IGrainActivationContext context, Orleans.Runtime.IPersistentStateConfiguration config) where TState : new();
public Orleans.Runtime.IPersistentState<TState> Create<TState> (Orleans.Runtime.IGrainActivationContext context, Orleans.Runtime.IPersistentStateConfiguration config);
abstract member Create : Orleans.Runtime.IGrainActivationContext * Orleans.Runtime.IPersistentStateConfiguration -> Orleans.Runtime.IPersistentState<'State (requires 'State : (new : unit -> 'State))> (requires 'State : (new : unit -> 'State))
abstract member Create : Orleans.Runtime.IGrainActivationContext * Orleans.Runtime.IPersistentStateConfiguration -> Orleans.Runtime.IPersistentState<'State>
Public Function Create(Of TState As New) (context As IGrainActivationContext, config As IPersistentStateConfiguration) As IPersistentState(Of TState)
Public Function Create(Of TState) (context As IGrainActivationContext, config As IPersistentStateConfiguration) As IPersistentState(Of TState)

類型參數

TState

參數

傳回

適用於

Create<TState>(IGrainContext, IPersistentStateConfiguration)

建立所提供之粒紋的永續性狀態實例。

public Orleans.Runtime.IPersistentState<TState> Create<TState> (Orleans.Runtime.IGrainContext context, Orleans.Runtime.IPersistentStateConfiguration config);
abstract member Create : Orleans.Runtime.IGrainContext * Orleans.Runtime.IPersistentStateConfiguration -> Orleans.Runtime.IPersistentState<'State>
Public Function Create(Of TState) (context As IGrainContext, config As IPersistentStateConfiguration) As IPersistentState(Of TState)

類型參數

TState

基礎狀態類型。

參數

context
IGrainContext

粒紋內容。

config
IPersistentStateConfiguration

狀態 Facet 組態。

傳回

所提供之粒紋的持續性狀態實例,具有指定的組態。

適用於