当前位置: 首页>>代码示例>>C#>>正文


C# ModelApplicationBase.RemoveLayer方法代码示例

本文整理汇总了C#中ModelApplicationBase.RemoveLayer方法的典型用法代码示例。如果您正苦于以下问题:C# ModelApplicationBase.RemoveLayer方法的具体用法?C# ModelApplicationBase.RemoveLayer怎么用?C# ModelApplicationBase.RemoveLayer使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ModelApplicationBase的用法示例。


在下文中一共展示了ModelApplicationBase.RemoveLayer方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: RemoveLayers

 IEnumerable<ModelApplicationBase> RemoveLayers(ModelApplicationBase modelApplicationBase, IEnumerable<string> strings) {
     var modelApplicationBases = new List<ModelApplicationBase>();
     while (modelApplicationBase.LastLayer.Id != "Unchanged Master Part") {
         if (!(strings.Contains(modelApplicationBase.LastLayer.Id)))
             modelApplicationBases.Add(modelApplicationBase.LastLayer);
         modelApplicationBase.RemoveLayer(modelApplicationBase.LastLayer);
     }
     return modelApplicationBases;
 }
开发者ID:gvilas,项目名称:eXpand,代码行数:9,代码来源:ModelApplicationLoader.cs

示例2: RefreshLayers

        static void RefreshLayers(ModelApplicationBase application,  Func<ModelApplicationBase, ModelApplicationBase> func) {
            var modelApplicationBases = new List<ModelApplicationBase>();
            var lastLayer = application.LastLayer;
            application.RemoveLayer(lastLayer);
            var afterSetup = application.LastLayer;
            application.RemoveLayer(afterSetup);
            while (application.LastLayer.Id != "Unchanged Master Part") {
                ModelApplicationBase modelApplicationBase = application.LastLayer;
                modelApplicationBase = func.Invoke(modelApplicationBase);
                if (modelApplicationBase!=null)
                    modelApplicationBases.Add(modelApplicationBase);
                application.RemoveLayer(application.LastLayer);
            }
            modelApplicationBases.Reverse();
            foreach (var modelApplicationBase in modelApplicationBases) {
                application.AddLayer(modelApplicationBase);
            }
            application.AddLayer(afterSetup);
            application.AddLayer(lastLayer);

        }
开发者ID:krazana,项目名称:eXpand,代码行数:21,代码来源:ModelApplicationBaseExtensions.cs

示例3: GetModelUnSafe

 void GetModelUnSafe(ModelApplicationBase modelApplicationBase, ModelDifferenceObject modelDifferenceObject) {
     var afterSetupLayer = GetAfterSetupLayer(modelApplicationBase);
     modelApplicationBase.AddLayer(afterSetupLayer);
     modelDifferenceObject.GetModel(modelApplicationBase);
     modelApplicationBase.RemoveLayer(afterSetupLayer);
 }
开发者ID:gvilas,项目名称:eXpand,代码行数:6,代码来源:ModelApplicationLoader.cs

示例4: CreateAspects

 public void CreateAspects(ModelApplicationBase model, ModelApplicationBase master) {
     var applicationBase = GetModel(master);
     new ModelXmlReader().ReadFromModel(applicationBase, model);
     CreateAspectsCore(model);
     //TODO:check this
     if (applicationBase != null) master.RemoveLayer(applicationBase);
 }
开发者ID:gvilas,项目名称:eXpand,代码行数:7,代码来源:ModelDifferenceObject.cs

示例5: CreateResourceRoleModels

 void CreateResourceRoleModels(ResourcesLayerBuilder resourcesLayerBuilder, Dictionary<string, ModelDifferenceObjectInfo> loadedModelDifferenceObjectInfos, ModelApplicationBase model) {
     var roleMarker = model.CreatorInstance.CreateModelApplication();
     roleMarker.Id = "RoleMarker";
     model.AddLayerBeforeLast(roleMarker);
     resourcesLayerBuilder.AddLayers(RoleApplicationPrefix, loadedModelDifferenceObjectInfos, model);
     var lastLayer = model.LastLayer;
     while (model.LastLayer.Id!="RoleMarker") {
         model.RemoveLayer(model.LastLayer);
     }
     model.RemoveLayer(roleMarker);
     model.AddLayer(lastLayer);
 }
开发者ID:gvilas,项目名称:eXpand,代码行数:12,代码来源:XpoModelDictionaryDifferenceStore.cs


注:本文中的ModelApplicationBase.RemoveLayer方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。