Skip to content

Associate signals with ports rather than variables #407

@PhilipFackler

Description

@PhilipFackler

Summary

As discussed in the comments in #401 change the enums that are used to define signal nodes on a component.

Rationale

Signal nodes should be associated with input/output ports rather than internal/external variables.

Description

  • Split the <component>Ports enum into <component>InputPorts, <component>OutputPorts, and <component>BusPorts (not sure about the name of that last one).
  • Add a SIZE member to the same (required for use in ComponentSignals)
  • Use input/output port enums as template arguments to ComponentSignals
  • Modify SignalComponents to use SIZE rather than MAXIMUM (more accurate)
  • Update input file documentation and component parser to specify ports separately

Additional information

For this change I would keep ComponentSignals basically as it is. But in future, it needs to be reworked a little to make it easier to use (and understand) in the code. This will be a good first step.

Metadata

Metadata

Assignees

Labels

developmentFeatures/Tools related to development of GridKit, rather than use as a library.enhancementNew feature or requestinvalidThis doesn't seem right

Type

No fields configured for Task.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions