本文整理汇总了C#中IPluginFinder.GetPlugins方法的典型用法代码示例。如果您正苦于以下问题:C# IPluginFinder.GetPlugins方法的具体用法?C# IPluginFinder.GetPlugins怎么用?C# IPluginFinder.GetPlugins使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类IPluginFinder
的用法示例。
在下文中一共展示了IPluginFinder.GetPlugins方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: WikiRenderer
public WikiRenderer(IPluginFinder pluginFinder, IWebContext webContext)
{
Renderers["Comment"] = new CommentRenderer();
Renderers["UserInfo"] = new UserInfoRenderer();
Renderers["InternalLink"] = new InternalLinkRenderer(webContext);
Renderers["ExternalLink"] = new ExternalLinkRenderer();
Renderers["Text"] = FallbackRenderer = new TextRenderer();
Renderers["Template"] = new TemplateRenderer(pluginFinder.GetPlugins<ITemplateRenderer>());
Renderers["Heading"] = new HeadingRenderer();
Renderers["Line"] = new LineRenderer();
Renderers["OrderedList"] = new OrderedListRenderer();
Renderers["UnorderedList"] = new UnorderedListRenderer();
Renderers["Format"] = new FormatRenderer();
}
示例2: AdminManager
public AdminManager(AdminSection configSection, ISecurityManager securityManager, IAdminAssemblyManager adminAssembly,
IAuthorizationService authorizationService, IAuthenticationContextService authenticationContextService,
IPersister persister, IVersionManager versionManager, IContentTypeManager contentTypeManager,
Web.IWebContext webContext, ILanguageManager languageManager,
IPluginFinder<ActionPluginGroupAttribute> actionPluginGroupFinder,
ITypeFinder typeFinder, IEmbeddedResourceManager embeddedResourceManager)
{
_configSection = configSection;
_securityManager = securityManager;
_adminAssembly = adminAssembly;
DeleteItemUrl = embeddedResourceManager.GetServerResourceUrl(adminAssembly.Assembly, "Zeus.Admin.Delete.aspx");
EditItemUrl = embeddedResourceManager.GetServerResourceUrl(adminAssembly.Assembly, "Zeus.Admin.Plugins.EditItem.Default.aspx");
NewItemUrl = embeddedResourceManager.GetServerResourceUrl(adminAssembly.Assembly, "Zeus.Admin.New.aspx");
EnableVersioning = configSection.Versioning.Enabled;
_authorizationService = authorizationService;
_authenticationContextService = authenticationContextService;
_persister = persister;
_versionManager = versionManager;
_contentTypeManager = contentTypeManager;
_webContext = webContext;
_languageManager = languageManager;
_cachedActionPluginGroups = actionPluginGroupFinder.GetPlugins().OrderBy(g => g.SortOrder);
}
示例3: ContentPropertyManager
public ContentPropertyManager(IPluginFinder<BasePropertyDataTypeAttribute> pluginFinder)
{
_propertyDataTypes = pluginFinder.GetPlugins().OrderBy(p => p.SortOrder);
}
示例4: InstantiateActions
private IEnumerable<ScheduledAction> InstantiateActions(IPluginFinder plugins)
{
foreach (ScheduleExecutionAttribute attr in plugins.GetPlugins<ScheduleExecutionAttribute>())
{
ScheduledAction action = Activator.CreateInstance(attr.Decorates) as ScheduledAction;
action.Interval = CalculateInterval(attr.Interval, attr.Unit);
action.Repeat = attr.Repeat;
yield return action;
}
}
示例5: RegisterActionsAsComponents
private void RegisterActionsAsComponents(IEngine engine, IPluginFinder plugins)
{
foreach (var plugin in plugins.GetPlugins<ScheduleExecutionAttribute>())
{
engine.Container.AddComponent(plugin.Decorates.FullName, plugin.Decorates, plugin.Decorates);
}
}