Mercurial > hg > Database > Christie-sharp
view topology/manager/StartTopologyManager.cs @ 71:1169915705ab default tip
fix TopologyNode connect
author | KaitoMaeshiro <aosskaito@cr.ie.u-ryukyu.ac.jp> |
---|---|
date | Sun, 06 Feb 2022 16:47:41 +0900 |
parents | 976d43003487 |
children |
line wrap: on
line source
using Christie_net.codegear; using Christie_net.topology.node; namespace Christie_net.topology.manager { public class StartTopologyManager : StartCodeGear { public StartTopologyManager(string[] args) : this(CreateCgm(new TopologyManagerConfig(args).localPort), new TopologyManagerConfig(args)){ } public StartTopologyManager(TopologyManagerConfig topologyManagerConfig) : this(CreateCgm(topologyManagerConfig.localPort), topologyManagerConfig){ } public StartTopologyManager(CodeGearManager cgm, TopologyManagerConfig topologyManagerConfig) : base(cgm) { cgm.Setup(new TopologyManager()); cgm.GetLocalDGM().Put("topologyManagerConfig", topologyManagerConfig); } public StartTopologyManager(TopologyManagerConfig conf, CodeGear startCG) : this(CreateCgm(conf.localPort), conf, startCG){ } public StartTopologyManager(CodeGearManager cgm, TopologyManagerConfig conf, CodeGear startCG) : base(cgm) { cgm.Setup(new TopologyManager()); cgm.Setup(new Start()); cgm.GetLocalDGM().Put("startCG", startCG); cgm.GetLocalDGM().Put("topologyNodeConfig", conf); } public static void Main(string[] args) { TopologyManagerConfig topologyManagerConfig = new TopologyManagerConfig(args); new StartTopologyManager(topologyManagerConfig); } } }