コード例 #1
0
        public void Create(ConfigElementNodeBuilder builder, ICollection <ConfigElementNode> elements,
                           ConfigElementNode elementNode)
        {
            elementNode.ElementName = Resources.ScenarioContainer;

            elementNode.RefreshCommand = new RefreshElementCommand(builder, elements, elementNode, MetadataType.Scenario);
            elementNode.RegisterAddCommands(builder, ElementChildrenTypes);
            elementNode.DeleteCommand = FactoryHelper.NoDeleteCommand;
            elementNode.CopyCommand   = FactoryHelper.NoCopyCommand;
            elementNode.RegisterPasteCommand(builder);

            FactoryHelper.AddEmptyElement(elements, elementNode);
        }
コード例 #2
0
        public void Create(ConfigElementNodeBuilder builder, ICollection <ConfigElementNode> elements, ConfigElementNode elementNode)
        {
            elementNode.DocumentId  = elementNode.ElementMetadata.Name;
            elementNode.ElementId   = FactoryHelper.BuildId(elementNode);
            elementNode.ElementName = FactoryHelper.BuildName(elementNode);

            elementNode.RefreshCommand = new RefreshContainerCommand(elementNode);
            elementNode.RegisterAddCommands(builder, ElementChildrenTypes);
            elementNode.RegisterEditCommand(builder);
            elementNode.DeleteCommand = new DeleteElementCommand(builder, elements, elementNode);
            elementNode.CopyCommand   = FactoryHelper.NoCopyCommand;
            elementNode.RegisterPasteCommand(builder);

            builder.BuildElement(elements, elementNode, elementNode.ElementMetadata, ViewContainerNodeFactory.ElementType);
            builder.BuildElement(elements, elementNode, elementNode.ElementMetadata, PrintViewContainerNodeFactory.ElementType);
            builder.BuildElement(elements, elementNode, elementNode.ElementMetadata, ScenarioContainerNodeFactory.ElementType);
            builder.BuildElement(elements, elementNode, elementNode.ElementMetadata, ProcessContainerNodeFactory.ElementType);
            builder.BuildElement(elements, elementNode, elementNode.ElementMetadata, ServiceContainerNodeFactory.ElementType);
        }