请问现在可以通过C#代码来实现廊道的构建么?

想要通过C#实现如下两个功能:

1、在一根线路上创建廊道;

2、在创建的廊道上应用Template drop生成路基模型

请问现在的ORD有提供这样的API么?

Parents
  • 以下代码示例如何通过路线创建一个廊道对象。

    CorridorEdit CreateCorridor(ConsensusConnectionEdit con,
    
        Alignment alignment,
    
        String strName)
    
    {
    
         CorridorEdit newCorridor = CorridorEdit.CreateByAlignment(con, strName , alignment);
    
         Return newCorridor;
    
    }

    以下代码示例如何在廊道对象上增加一个模板应用对象。

    void CreateTemplateDrop(CorridorEdit corridor,
    
            double startStation,
    
            double endStation,
    
            TemplateDefinition tempDef)
    
    {
    
        TemplateDropParameters tempDropParams = new TemplateDropParameters(tempDef, startStation, endStation);
    
        tempDropParams.Interval = 5.0;
    
        tempDropParams.Desription = "Test Add TemplateDrop";
    
        TemplateDropEdit templateDrop = corridor.AddTemplateDrop(tempDropParams);
    
    
    
        Return templateDrop;
    
    }

    以下代码示例如何将一个模板应用对象分割为多个模板应用对象:

    IList<TemplateDropEdit> SplitTemplateDrop(TemplateDropEdit templateDropEdit)
    
    {
    
        System.Collections.Generic.List<double> station = new List<double>();
    
        station.Add(3000.00);
    
        station.Add(6000.00);
    
        IList<TemplateDropEdit> newTemplateDrops = templateDropEdit.Split(station);
    
    Return newTemplateDrops;
    
    }

  • 张总,我试了下你发的构建廊道方法,这个CorrdiorEdit对象好像是个Internal对象访问不了呀,

    后面的CreateByAlignment方法好像页没有找打。

Reply Children