static void ShowBundles(IBundleService bundleService, string bundleName = "") { foreach (var bundle in bundleService.GetAll(bundleName)) { System.Console.WriteLine(bundle.Name + " " + string.Join(", ", bundle.Tags)); } }
static void ShowBundles(IBundleService bundleService, string bundleName = "") { foreach (var bundle in bundleService.GetAll(bundleName)) { System.Console.WriteLine(bundle.Name + " " + string.Join(", ", bundle.Tags)); } }
public BundleController() { bundleService = new BundleService(); locationService = new LocationService(); resourceService = new ResourceService(); userService = new UserService(); }
public BackerMenu(ICreatorService _creatorService, IBackerService _backerService, IProjectService projects, IBundleService bundles, AppDbContext appDbContext) { creatorService = _creatorService; backerService = _backerService; projects_ = projects; bundles_ = bundles; this.dbContext = appDbContext; }
public VersionService(IUnitOfWork unitOfWork, IMapper mapper, IBundleService bundleService) { _unitOfWork = unitOfWork; _mapper = mapper; _bundleService = bundleService; }
public ContactPage(IBundleService bundleService , IIconResourceService iconResourceService , IPageService pageService , IVirtualFileSystem virtualFileSystem , IDbSessionFactory sessionFactory) : base(bundleService, iconResourceService, pageService, virtualFileSystem) { m_sessionFactory = sessionFactory; }
public ActivityPageNavigationService( IBundleService bundleService, IViewLocator viewLocator, IContextProvider contextProvider) { _bundleService = bundleService; _viewLocator = viewLocator; _contextProvider = contextProvider; }
public MailPage(IBundleService bundleService , IIconResourceService iconResourceService , IPageService pageService , IVirtualFileSystem virtualFileSystem , IDbSessionFactory sessionFactory) : base(bundleService, iconResourceService, pageService, virtualFileSystem) { m_sessionFactory = sessionFactory; Initialize(); }
public ExtensionBuilder(IAssemblyLoaderService assemblyLoader , IBundleService bundleService , IExtensionRegistry registry , IObjectBuilder objectBuilderService) { _assemblyLoaderService = assemblyLoader; _bundleService = bundleService; _registry = registry; _objectBuilderService = objectBuilderService; }
/// <summary> /// Initializes a new instance of the <see cref="VersionController"/> class. /// </summary> /// <param name="versionService">The version service.</param> /// <param name="apkService">The apk service.</param> /// <param name="mapper">The mapper.</param> public VersionController(IVersionService versionService, IMapper mapper, IBundleService bundleService, IDeviceConfigService deviceConfigService) { _versionService = versionService; _mapper = mapper; _bundleService = bundleService; _deviceConfigService = deviceConfigService; }
public BundleAdminController( IBundleService bundleService, IBundleAutocompleteService bundleAutocompleteService, IContentManager contentManager, IProductInventoryService productInventoryService) { _bundleService = bundleService; _bundleAutocompleteService = bundleAutocompleteService; _contentManager = contentManager; _productInventoryService = productInventoryService; }
public CreatorMenu(ICreatorService _creatorService, IBackerService _backerService, IProjectService _projectService, IBundleService _bundleService, AppDbContext appDbContext) { creatorService = _creatorService; backerService = _backerService; projectService = _projectService; bundleService = _bundleService; this.dbContext = appDbContext; }
public BundlePartDriver( IBundleService bundleService, IBundleAutocompleteService bundleAutocompleteService, IContentManager contentManager, IOrchardServices orchardServices) { _bundleService = bundleService; _bundleAutocompleteService = bundleAutocompleteService; _contentManager = contentManager; _orchardServices = orchardServices; }
public TreePage(IBundleService bundleService , IIconResourceService iconResourceService , IPageService pageService , IVirtualFileSystem virtualFileSystem) { m_BundleService = bundleService; m_IconResourceService = iconResourceService; m_ToolStripFactory = pageService.PageLayoutProvider.ToolbarFactory; m_VirtualFileSystem = virtualFileSystem; }
public ProjectController(IProjectService _projectService, ILogger <ProjectController> logger, IBackerService _backerService, IBundleService _bundleService, ITagService _tagService, IWebHostEnvironment _hostingEnvironment, AppDbContext appDbContext) { projectService = _projectService; bundleService = _bundleService; backerService = _backerService; tagService = _tagService; hostingEnvironment = _hostingEnvironment; _logger = logger; this.dbContext = appDbContext; }
public ExtensionRegistry(IBundleService bundleService , IAssemblyLoaderService assemblyLoaderService , IObjectBuilder builderService , IApplicationContext context) { _bundleService = bundleService; _context = context; _extensionBuilder = new ExtensionBuilder(assemblyLoaderService, bundleService, this, builderService); _serializable = new Serializable(); _serializable.Registry = this; _serializable.ExtensionBuilder = _extensionBuilder; }
public MessageExplorer(IBundleService bundleService , IIconResourceService iconResourceService , IDbSessionFactory sessionFactory , IPartRegistry partRegistry , IPageService pageService , IVirtualFileSystem virtualFileSystem) { m_BundleService = bundleService; m_IconResourceService = iconResourceService; m_sessionFactory = sessionFactory; m_PartRegistry = partRegistry; m_PageService = pageService; m_ToolStripFactory = pageService.PageLayoutProvider.ToolbarFactory; m_VirtualFileSystem = virtualFileSystem; }
static void Main(string[] args) { // init Configuration.Configure() .SetUserName("test") .SePassword("qwerty"); IKernel kernel = new StandardKernel(new DeliciousModule()); IPostService postService = kernel.Get <PostService>(); ITagService tagService = kernel.Get <TagService>(); IBundleService bundleService = kernel.Get <BundleService>(); // test ShowPosts(postService); //ShowTags(tagService); //ShowDeliciousDates(postService, "cqrs"); //ShowPostHashes(postService); //ShowSuggests(postService, "http://php.net"); //ShowBundles(bundleService); }
public MessageExplorerWidget(IBundleService bundleService , IIconResourceService iconResourceService , IDbSessionFactory sessionFactory , IPartRegistry partRegistry , IPageService pageService , IVirtualFileSystem virtualFileSystem , IViewPart viewPart) { m_BundleService = bundleService; m_IconResourceService = iconResourceService; m_sessionFactory = sessionFactory; m_PartRegistry = partRegistry; m_PageService = pageService; m_ToolStripFactory = pageService.PageLayoutProvider.ToolbarFactory; m_VirtualFileSystem = virtualFileSystem; m_viewPart = viewPart; InitializeComponent(); m_image_mail = iconResourceService.GetImage("jingxian.ui.icons.mail.png"); m_image_open_mail = iconResourceService.GetIcon("jingxian.ui.icons.maillist.open_mail.ico").ToBitmap(); m_image_close_mail = iconResourceService.GetIcon("jingxian.ui.icons.maillist.close_mail.ico").ToBitmap(); m_image_litter_point = iconResourceService.GetImage("jingxian.ui.icons.maillist.litter_point.png"); m_image_big_point = iconResourceService.GetImage("jingxian.ui.icons.maillist.big_point.png"); m_image_spam = iconResourceService.GetImage("jingxian.ui.icons.maillist.spam.png"); m_image_red_flag = iconResourceService.GetImage("jingxian.ui.icons.maillist.red_flag.png"); m_image_gray_flag = iconResourceService.GetImage("jingxian.ui.icons.maillist.gray_flag.png"); m_image_right = iconResourceService.GetImage("jingxian.ui.icons.maillist.right.png"); m_image_open_mail = iconResourceService.GetIcon("jingxian.ui.icons.maillist.open_mail.ico").ToBitmap(); m_image_close_mail = iconResourceService.GetIcon("jingxian.ui.icons.maillist.close_mail.ico").ToBitmap(); m_image_litter_point = iconResourceService.GetBitmap("jingxian.ui.icons.maillist.litter_point.png"); m_image_big_point = iconResourceService.GetBitmap("jingxian.ui.icons.maillist.big_point.png"); m_image_spam = iconResourceService.GetBitmap("jingxian.ui.icons.maillist.spam.png"); m_image_red_flag = iconResourceService.GetBitmap("jingxian.ui.icons.maillist.red_flag.png"); m_image_gray_flag = iconResourceService.GetBitmap("jingxian.ui.icons.maillist.gray_flag.png"); m_image_right = iconResourceService.GetBitmap("jingxian.ui.icons.maillist.right.png"); LoadAllMessages(); string startView = null; System.IO.TextReader textReader = new System.IO.StringReader(m_viewPart.ConfigurationXml); using (XmlReader reader = XmlReader.Create(textReader, XmlUtils.CreateFragmentReaderSettings(), XmlUtils.CreateParserContext())) { if (reader.IsStartElement("view")) { startView = XmlUtils.ReadRequiredAttributeString(reader, "ref"); } } if (string.IsNullOrEmpty(startView)) { return; } IWorkbenchPart welcomePart; m_PartRegistry.TryGet(jingxian.ui.Constants.WelcomeId, out welcomePart); if (null == welcomePart) { return; } UserControl control = new UserControl(); control.BorderStyle = BorderStyle.Fixed3D; control.Dock = DockStyle.Fill; this.m_splitter.Panel2.Controls.Add(control); Control welcomePage = welcomePart.Widget; welcomePage.Dock = DockStyle.Fill; control.Controls.Add(welcomePage); }
public BundleController(IBundleService bundleService, IMapper mapper) { this.bundleService = bundleService; this.mapper = mapper; }
public ActionResult List() { bundleService = new BundleService(); var model = new BundlesModel(); model.bundles = bundleService.GetAllBundles(); model.number_of_tasks = new Dictionary<int, int>(); foreach (Bundle bundle in model.bundles) { model.number_of_tasks.Add(bundle.id, bundleService.GetTasksCount(bundle.id)); } return View(model); }
public BundlesController() { _bundleService = IoCFactory.Resolve<IBundleService>(); }
public BundleController(IBundleService service) { this.service = service; }
public BundleController(IBundleService service) { this.service = service; }
public BundleAdminController(IBundleService bundleService, IContentManager contentManager) { _bundleService = bundleService; _contentManager = contentManager; }
public BundlesController() { _bundleService = IoCFactory.Resolve <IBundleService>(); }
public BundlePartDriver(IBundleService bundleService, IContentManager contentManager) { _bundleService = bundleService; _contentManager = contentManager; }
public BundleAdminController(IBundleService bundleService, IContentManager contentManager) { _bundleService = bundleService; _contentManager = contentManager; }
public ListExplorer(IBundleService bundleService , IIconResourceService iconResourceService , IPartRegistry partRegistry , IPageService pageService , IVirtualFileSystem virtualFileSystem , IViewPart viewPart) { m_BundleService = bundleService; m_IconResourceService = iconResourceService; m_PartRegistry = partRegistry; m_PageService = pageService; m_ToolStripFactory = pageService.PageLayoutProvider.ToolbarFactory; m_VirtualFileSystem = virtualFileSystem; m_viewPart = viewPart; InitializeComponent(); DataExplorerConfiguration config = null; System.IO.TextReader textReader = new System.IO.StringReader(m_viewPart.ConfigurationXml); using (XmlReader reader = XmlReader.Create(textReader, XmlUtils.CreateFragmentReaderSettings(), XmlUtils.CreateParserContext())) { config = XmlUtils.ReadElement <DataExplorerConfiguration>(reader, "dataExplorer"); } foreach (ColumnModelConfiguration columnConfiguration in config.Table.Columns) { IFieldDescriptor descriptor = CreateDescriptor(columnConfiguration.Type); if (!string.IsNullOrEmpty(columnConfiguration.Text)) { descriptor.Column.Text = columnConfiguration.Text; } if (!string.IsNullOrEmpty(columnConfiguration.Format)) { descriptor.Column.Format = columnConfiguration.Format; } if (!string.IsNullOrEmpty(columnConfiguration.Alignment)) { descriptor.Column.Alignment = (ColumnAlignment)Enum.Parse(typeof(ColumnAlignment), columnConfiguration.Alignment); } if (0 > columnConfiguration.Width) { descriptor.Column.Width = columnConfiguration.Width; } if (0 > columnConfiguration.ContentWidth) { descriptor.Column.ContentWidth = columnConfiguration.ContentWidth; } if (!string.IsNullOrEmpty(columnConfiguration.Image)) { descriptor.Column.Image = iconResourceService.GetImage(columnConfiguration.Image); } if (!columnConfiguration.ImageOnRight) { descriptor.Column.ImageOnRight = columnConfiguration.ImageOnRight; } if (!columnConfiguration.Visible) { descriptor.Column.Visible = columnConfiguration.Visible; } if (!columnConfiguration.Sortable) { descriptor.Column.Sortable = columnConfiguration.Sortable; } if (!columnConfiguration.Resizable) { descriptor.Column.Resizable = columnConfiguration.Resizable; } //if (!string.IsNullOrEmpty(columnConfiguration.DefaultComparerType)) // descriptor.Column.DefaultComparerType = Type.GetType( columnConfiguration.DefaultComparerType ); //if (!string.IsNullOrEmpty(columnConfiguration.SortOrder)) // descriptor.Column.SortOrder =(SortOrder)Enum.Parse(typeof(SortOrder), columnConfiguration.SortOrder ); if (!columnConfiguration.Editable) { descriptor.Column.Editable = columnConfiguration.Editable; } if (!columnConfiguration.Enabled) { descriptor.Column.Enabled = columnConfiguration.Enabled; } if (!columnConfiguration.Selectable) { descriptor.Column.Selectable = columnConfiguration.Selectable; } if (!string.IsNullOrEmpty(columnConfiguration.ToolTipText)) { descriptor.Column.ToolTipText = columnConfiguration.ToolTipText; } _fieldDescriptors.Add(descriptor); } }
internal static XmlSchema CreateFromContributions(IExtensionRegistry registry, IBundleService bundleService, IAssemblyLoaderService assemblyLoader) { IExtension[] extensions = registry.GetExtensions(Constants.Points.XmlSchemas); XmlSchema extensionSchema = new XmlSchema(); XmlSchema[] contributedSchemas = GetContributedXmlSchemas(extensions, bundleService, assemblyLoader); for (int i = 0; i < contributedSchemas.Length; i++) { CopyAllItemTypes(contributedSchemas[i], extensionSchema.Items); } extensionSchema.AttributeFormDefault = XmlSchemaForm.Unqualified; extensionSchema.ElementFormDefault = XmlSchemaForm.Qualified; extensionSchema.Version = typeof(ExtensionXmlSchema).Assembly.GetName().Version.ToString(); extensionSchema.Namespaces.Add(string.Empty, RuntimeConstants.CurrentXmlSchemaNamespace); extensionSchema.TargetNamespace = RuntimeConstants.CurrentXmlSchemaNamespace; return(extensionSchema); }
private static XmlSchema[] GetContributedXmlSchemas(IEnumerable <IExtension> xmlSchemaExtensions, IBundleService bundleService, IAssemblyLoaderService assemblyLoader) { List <XmlSchema> contributedSchemas = new List <XmlSchema>(); foreach (IExtension ext in xmlSchemaExtensions) { IBundle bundle; if (!bundleService.TryGetBundleForExtension(ext.Id, out bundle)) { throw new PlatformConfigurationException( string.Format(CultureInfo.InvariantCulture, "不能为扩展 '{0}' 获取 Bundle .跳过它.", ext.Id)); } Assembly assembly; if (assemblyLoader.TryGetLoadedAssembly( Utils.GetAssemblySimpleNameFromLocation(bundle.AssemblyLocation), out assembly)) { if (ext.HasImplementation) { XmlSchema schema = XmlUtils.GetSchema(assembly, ext.Implementation); contributedSchemas.Add(schema); } } else { if (assemblyLoader.TryLoadAssembly( Utils.GetAssemblyFileNameFromLocation(bundle.AssemblyLocation), out assembly)) { if (ext.HasImplementation) { XmlSchema schema = XmlUtils.GetSchema(assembly, ext.Implementation); contributedSchemas.Add(schema); } } else { throw new PlatformConfigurationException( string.Format("不能载入程序集 '{0}' 中的 XML Schema 扩展 '{1}'. 跳过它.", bundle.AssemblyLocation, ext.Id)); } } } return(contributedSchemas.ToArray()); }
public ValuesController() { bundleService = new BundleService(); accountService = new AccountService(); locationService = new LocationService(); }