Example #1
0
 public UIPropertyEditorByIdDataProducer(IUIPropertyEditorPropertiesAvailableStatus properties, IProjectService2 projectService)
 {
     Requires.NotNull(properties, nameof(properties));
     Requires.NotNull(projectService, nameof(projectService));
     _properties     = properties;
     _projectService = projectService;
 }
        public static async Task <IEntityValue?> CreatePropertyPageValueAsync(
            IQueryExecutionContext queryExecutionContext,
            EntityIdentity id,
            IProjectService2 projectService,
            IProjectStateProvider projectStateProvider,
            QueryProjectPropertiesContext propertiesContext,
            string propertyPageName,
            IPropertyPagePropertiesAvailableStatus requestedProperties)
        {
            if (projectService.GetLoadedProject(propertiesContext.File) is UnconfiguredProject project)
            {
                project.GetQueryDataVersion(out string versionKey, out long versionNumber);
                queryExecutionContext.ReportInputDataVersion(versionKey, versionNumber);

                if (await project.GetProjectLevelPropertyPagesCatalogAsync() is IPropertyPagesCatalog projectCatalog &&
                    projectCatalog.GetSchema(propertyPageName) is Rule rule &&
                    !rule.PropertyPagesHidden)
                {
                    IProjectState projectState      = projectStateProvider.CreateState(project);
                    IEntityValue  propertyPageValue = CreatePropertyPageValue(queryExecutionContext, id, projectState, propertiesContext, rule, requestedProperties);
                    return(propertyPageValue);
                }
            }

            return(null);
        }
Example #3
0
 public UIPropertyByIdProducer(IUIPropertyPropertiesAvailableStatus properties, IProjectService2 projectService, IProjectStateProvider projectStateProvider)
 {
     Requires.NotNull(properties, nameof(properties));
     Requires.NotNull(projectService, nameof(projectService));
     _properties           = properties;
     _projectService       = projectService;
     _projectStateProvider = projectStateProvider;
 }
Example #4
0
        public CategoryByIdDataProducer(ICategoryPropertiesAvailableStatus properties, IProjectService2 projectService)
        {
            Requires.NotNull(properties, nameof(properties));
            Requires.NotNull(projectService, nameof(projectService));

            _properties     = properties;
            _projectService = projectService;
        }
Example #5
0
        public PropertyPageByIdDataProducer(IPropertyPagePropertiesAvailableStatus properties, IProjectService2 projectService)
        {
            Requires.NotNull(properties, nameof(properties));
            Requires.NotNull(projectService, nameof(projectService));

            _projectService = projectService;
            _properties     = properties;
        }
Example #6
0
        public PropertyPageByIdDataProducer(IPropertyPagePropertiesAvailableStatus properties, IProjectService2 projectService, IPropertyPageQueryCacheProvider queryCacheProvider)
        {
            Requires.NotNull(properties, nameof(properties));
            Requires.NotNull(projectService, nameof(projectService));
            Requires.NotNull(queryCacheProvider, nameof(queryCacheProvider));

            _properties         = properties;
            _projectService     = projectService;
            _queryCacheProvider = queryCacheProvider;
        }
Example #7
0
 public CategoryByIdDataProducer(ICategoryPropertiesAvailableStatus properties, IProjectService2 projectService)
 {
     _properties     = properties;
     _projectService = projectService;
 }
Example #8
0
 public LaunchProfileByIdDataProducer(ILaunchProfilePropertiesAvailableStatus properties, IProjectService2 projectService)
 {
     _properties     = properties;
     _projectService = projectService;
 }