public CyPhyBuildVisitor(string projectDirectory, CodeGenerator.Mode mode) // this is a singleton object and the constructor will be called once { Components = new Dictionary<string, Component>(); ComponentInstanceGUIDs = new Dictionary<string, Component>(); Ports = new Dictionary<string, Port>(); Components.Clear(); ComponentInstanceGUIDs.Clear(); Ports.Clear(); this.ProjectDirectory = projectDirectory; this.mode = mode; }
public CyPhyBuildVisitor(string projectDirectory, CodeGenerator.Mode mode, MgaTraceability traceability, Dictionary <string, CyPhy2Schematic.CyPhy2SchematicInterpreter.IDs> mgaIdToDomainIDs, ISet <IMgaObject> selectedSpiceModels) // this is a singleton object and the constructor will be called once { Components = new Dictionary <string, Component>(); ComponentInstanceGUIDs = new Dictionary <string, Component>(); Ports = new Dictionary <string, Port>(); this.ProjectDirectory = projectDirectory; this.mode = mode; this.Traceability = traceability; this.mgaIdToDomainIDs = mgaIdToDomainIDs; this.selectedSpiceModels = selectedSpiceModels; }
public CyPhyConnectVisitor(CodeGenerator.Mode mode) { VisitedPorts = new Dictionary <string, Port>(); this.mode = mode; switch (mode) { case CodeGenerator.Mode.EDA: SchematicModelType = typeof(Tonka.EDAModel); break; case CodeGenerator.Mode.SPICE: case CodeGenerator.Mode.SPICE_SI: SchematicModelType = typeof(Tonka.SPICEModel); break; default: throw new NotSupportedException(String.Format("Mode {0} is not supported.", mode.ToString())); } }
public CyPhyConnectVisitor(CodeGenerator.Mode mode) { VisitedPorts = new Dictionary<string, Port>(); VisitedPorts.Clear(); this.mode = mode; switch (mode) { case CodeGenerator.Mode.EDA: SchematicModelType = typeof(Tonka.EDAModel); break; case CodeGenerator.Mode.SPICE: case CodeGenerator.Mode.SPICE_SI: SchematicModelType = typeof(Tonka.SPICEModel); break; default: throw new NotSupportedException(String.Format("Mode {0} is not supported.", mode.ToString())); } }