CompSlotName
|
A string marking a specific integer value in a case of ComponentType.
The values here are arbitrary and ComponentType-case specific and all that matters is that each value is unique
within the case.
|
ComponentSlotExpr
|
For Part A: alternatively you could store slot information in the component record
as an extra field.
This field should store all the Component's slot information where slots are bound to parameters.
|
ConstrainedExpr
|
A parameter expression and its corresponding constraints
|
NewParamCompSpec
|
Data for a new parameterised slot being created
|
ParamBindings
|
Map from name to expression for each parameter
|
ParamBoxDialogState
|
The Elmish Model state used to manage input boxes that can be used to define parameter expressions.
Part of Model.PopupDialogData.DialogState.
|
ParamConstraint
|
For MVP could allow only PInt case constraints
The Errors are human-readable explanations of why violating the constraint is not allowed.
They should if possible be component-specific "constant MyConstName is 3 bit width so not allowed to be less than -4".
|
ParamError
|
|
ParamExpression
|
An arithmetic expression containing symbolic parameters
For MVP this could be limited to PInt and PParameter only.
However, it would be useful to have a more general type definition so that
functions that manipulate constraints, parameters, etc can be written in a more general way.
The actual parameter value is customisable so that the same code can be used for int parameters (normal)
and BigInt parameters (needed for constant values in N bit components).
For MVP set 'PINT = int
TODO: refactor this to use an enumeration DU for operators to reduce cases.
|
ParamInt
|
Probably needs to be bigint eventually to deal with the value of an N bit constant for n > 32.
|
ParamName
|
A named parameter in a custom component type
For MVP this is ok but maybe names need to be qualified by the
design sheet they are in to make functions support parameter inheritance.
|
ParamSlot
|
A slot in a component instance that can be bound to a parameter expression
CompId should be a ComponentId but then we would need these types to be defined after CommonTypes.
That is not possible, because we will wnat to modify CommonTypes types to use these!
eventually these types can be folded into CommonTypes, and that could if need be be made recursive so
solving the problem.
In practice this is OK because ParamSlot is strongly typed and we will not be likely to confused CompID with any
other string.
|
ParameterDefs
|
The state used per design sheet to define integer slots
that have values defined with parameter expressions
LoadedComponent.LCParameterSlots
(also used in SheetInfo - to save / load files - but the LoadedComponent field is the only one used by HLP Teams)
|