本文整理汇总了C#中ComponentInstanceDelegate类的典型用法代码示例。如果您正苦于以下问题:C# ComponentInstanceDelegate类的具体用法?C# ComponentInstanceDelegate怎么用?C# ComponentInstanceDelegate使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ComponentInstanceDelegate类属于命名空间,在下文中一共展示了ComponentInstanceDelegate类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ServiceCreatorCallbackActivator
public ServiceCreatorCallbackActivator(ComponentModel model,
IKernel kernel, ComponentInstanceDelegate onCreation,
ComponentInstanceDelegate onDestruction) :
base(model, kernel, onCreation, onDestruction)
{
// Nothing to do
}
示例2: SessionFactoryActivator
/// <summary>
/// Constructor for SessionFactoryActivator
/// </summary>
/// <param name="model"></param>
/// <param name="kernel"></param>
/// <param name="onCreation"></param>
/// <param name="onDestruction"></param>
public SessionFactoryActivator(ComponentModel model,
IKernelInternal kernel,
ComponentInstanceDelegate onCreation,
ComponentInstanceDelegate onDestruction)
: base(model, kernel, onCreation, onDestruction)
{
}
示例3: CreateOnUIThreadActivator
/// <summary>
/// Initializes a new instance of the <see cref = "CreateOnUIThreadActivator" /> class.
/// </summary>
/// <param name = "model">The model.</param>
/// <param name = "kernel">The kernel.</param>
/// <param name = "onCreation">Delegate called on construction.</param>
/// <param name = "onDestruction">Delegate called on destruction.</param>
public CreateOnUIThreadActivator(ComponentModel model, IKernel kernel, ComponentInstanceDelegate onCreation,
ComponentInstanceDelegate onDestruction)
: base(model, kernel, onCreation, onDestruction)
{
customActivator = CreateCustomActivator(model, kernel);
performCreation = PerformCreation;
}
示例4: DefaultComponentActivator
/// <summary>
/// Initializes a new instance of the <see cref = "DefaultComponentActivator" /> class.
/// </summary>
/// <param name = "model"></param>
/// <param name = "kernel"></param>
/// <param name = "onCreation"></param>
/// <param name = "onDestruction"></param>
public DefaultComponentActivator(ComponentModel model, IKernel kernel, ComponentInstanceDelegate onCreation, ComponentInstanceDelegate onDestruction)
: base(model, kernel, onCreation, onDestruction)
{
#if (!SILVERLIGHT)
useFastCreateInstance = !model.Implementation.IsContextful && new SecurityPermission(SecurityPermissionFlag.SerializationFormatter).IsGranted();
#endif
}
示例5: AbstractComponentActivator
/// <summary>
/// Constructs an AbstractComponentActivator
/// </summary>
protected AbstractComponentActivator(ComponentModel model, IKernel kernel, ComponentInstanceDelegate onCreation, ComponentInstanceDelegate onDestruction)
{
this.model = model;
this.kernel = kernel;
this.onCreation = onCreation;
this.onDestruction = onDestruction;
}
示例6: ControlComponentActivator
/// <summary>
/// Initializes a new instance of the <see cref="ControlComponentActivator"/> class.
/// </summary>
/// <param name="model">The model.</param>
/// <param name="kernel">The kernel.</param>
/// <param name="onCreation">Delegate called on construction.</param>
/// <param name="onDestruction">Delegate called on destruction.</param>
public ControlComponentActivator(ComponentModel model, IKernel kernel,
ComponentInstanceDelegate onCreation,
ComponentInstanceDelegate onDestruction)
: base(model, kernel, onCreation, onDestruction)
{
instantiateInMainThread = InstantiateInMainThread;
}
示例7: DefaultComponentActivator
/// <summary>
/// Initializes a new instance of the <see cref="DefaultComponentActivator"/> class.
/// </summary>
/// <param name="model"></param>
/// <param name="kernel"></param>
/// <param name="onCreation"></param>
/// <param name="onDestruction"></param>
public DefaultComponentActivator(ComponentModel model, IKernel kernel,
ComponentInstanceDelegate onCreation,
ComponentInstanceDelegate onDestruction)
: base(model, kernel, onCreation, onDestruction)
{
useFastCreateInstance = !model.Implementation.IsContextful && SecurityManager.IsGranted(new SecurityPermission(SecurityPermissionFlag.SerializationFormatter));
}
示例8: LoggerActivator
public LoggerActivator(
ComponentModel model,
IKernel kernel,
ComponentInstanceDelegate onCreation,
ComponentInstanceDelegate onDestruction)
: base(model, (IKernelInternal)kernel, onCreation, onDestruction)
{
}
示例9: ContextStoreInstanceActivator
public ContextStoreInstanceActivator(
ComponentModel model,
IKernel kernel,
ComponentInstanceDelegate onCreation,
ComponentInstanceDelegate onDestruction) : base(model, kernel, onCreation, onDestruction)
{
this.storeKey = model.Name;
}
示例10: ViewComponentActivator
public ViewComponentActivator(ComponentModel model, IKernel kernel, ComponentInstanceDelegate onCreation, ComponentInstanceDelegate onDestruction)
: base(model, kernel, onCreation, onDestruction)
{
ViewType = Model.Implementation;
ViewModelType = Model.Implementation
.GetInterfaces()
.Where(i => i.IsGenericType && i.GetGenericTypeDefinition() == typeof(IView<>))
.Select(i => i.GetGenericArguments().First())
.First();
}
示例11: DynamicLoaderActivator
/// <summary>
/// Creates a new <see cref="DynamicLoaderActivator"/>.
/// </summary>
public DynamicLoaderActivator(ComponentModel model, IKernel kernel, ComponentInstanceDelegate onCreation,
ComponentInstanceDelegate onDestruction)
: base(model, kernel, onCreation, onDestruction)
{
if (!model.Implementation.IsSubclassOf(typeof(MarshalByRefObject)))
throw new FacilityException(
String.Format(
"The implementation for the component '{0}' must inherit from System.MarshalByRefObject in order to be created in an isolated AppDomain.",
model.Name));
this.loader = (RemoteLoader) model.ExtendedProperties["dynamicLoader.loader"];
if (this.loader == null)
throw new FacilityException(String.Format("A remote loader was not created for component '{0}'.", model.Name));
}
示例12: RemoteMarshallerActivator
/// <summary>
/// Initializes a new instance of the <see cref="RemoteMarshallerActivator"/> class.
/// </summary>
/// <param name="model">The model.</param>
/// <param name="kernel">The kernel.</param>
/// <param name="onCreation">The oncreation event handler.</param>
/// <param name="onDestruction">The ondestruction event handler.</param>
public RemoteMarshallerActivator(ComponentModel model, IKernel kernel, ComponentInstanceDelegate onCreation, ComponentInstanceDelegate onDestruction) : base(model, kernel, onCreation, onDestruction)
{
}
示例13: WebUserControlComponentActivator
/// <summary>
/// Initializes a new instance of the <see cref="WebUserControlComponentActivator"/> class.
/// </summary>
/// <param name="model">The model.</param>
/// <param name="kernel">The kernel.</param>
/// <param name="onCreation">The on creation.</param>
/// <param name="onDestruction">The on destruction.</param>
public WebUserControlComponentActivator(ComponentModel model, IKernel kernel,
ComponentInstanceDelegate onCreation,
ComponentInstanceDelegate onDestruction)
: base(model, kernel, onCreation, onDestruction)
{
}
示例14: AspectEngineActivator
public AspectEngineActivator(ComponentModel model, IKernel kernel,
ComponentInstanceDelegate onCreation, ComponentInstanceDelegate onDestruction) :
base(model, kernel, onCreation, onDestruction)
{
}
示例15: RemoteActivatorThroughConnector
/// <summary>
/// Initializes a new instance of the <see cref = "RemoteActivatorThroughConnector" /> class.
/// </summary>
/// <param name = "model">The model.</param>
/// <param name = "kernel">The kernel.</param>
/// <param name = "onCreation">The oncreation event handler.</param>
/// <param name = "onDestruction">The ondestruction event handler.</param>
public RemoteActivatorThroughConnector(ComponentModel model, IKernel kernel, ComponentInstanceDelegate onCreation, ComponentInstanceDelegate onDestruction)
: base(model, kernel, onCreation, onDestruction)
{
}