Comments (3)
Hi Irina, the schema is actually correct, as far as I can see, in that fmi3Enumeration
is an extension of fmi3MandatorilyTypedInitializableVariable
, which is an extension of fmi3MandatorilyTypedArrayableVariable
, which is an extension of fmi3TypedArrayableVariable
, which is an extension of fmi3ArrayableVariable
which has the Dimension
elements, which is again an extension of fmi3AbstractVariable
, which has the Annotations
element.
I don't know where the second diagram is coming from, but it seems that that program does not show the inherited/extension base content, but only the added content, leading to the confusion?
from fmi-standard.
Hi Pierre, I think there is a bug in fmi3MandatorilyTypedArrayableVariable
. It is not an extension of fmi3TypedArrayableVariable
but fmi3TypedArrayableVariable
is specified as restriction:
<xs:complexType name="fmi3MandatorilyTypedArrayableVariable" abstract="true">
<xs:complexContent>
<xs:restriction base="fmi3TypedArrayableVariable">
<xs:attribute name="declaredType" type="xs:normalizedString" use="required"/>
</xs:restriction>
</xs:complexContent>
</xs:complexType>
I guess that this would be correct:
<xs:complexType name="fmi3MandatorilyTypedArrayableVariable" abstract="true">
<xs:complexContent>
<xs:extension base="fmi3TypedArrayableVariable">
<xs:attribute name="declaredType" type="xs:normalizedString" use="required"/>
</xs:extension>
</xs:complexContent>
</xs:complexType>
But then the declaredType attribute must be treated in a different way.
from fmi-standard.
Hi Irina,
there is indeed a bug in the definition, however it should be a restriction (otherwise the use required would not be allowed/make sense); the real bug is that somewhere along the line the non-attribute content was not/no longer repeated in the restriction, as it should have been... probably my bad...
the fix would look like this:
<xs:group name="fmi3Dimensions">
<xs:sequence>
<xs:element name="Dimension" minOccurs="0" maxOccurs="unbounded">
<xs:complexType>
<xs:attribute name="start" type="xs:unsignedLong"/>
<xs:attribute name="valueReference" type="xs:unsignedInt"/>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:group>
<xs:complexType name="fmi3ArrayableVariable" abstract="true">
<xs:complexContent>
<xs:extension base="fmi3AbstractVariable">
<xs:group ref="fmi3Dimensions"/>
<xs:attribute name="intermediateUpdate" type="xs:boolean"/>
<xs:attribute name="previous" type="xs:unsignedInt"/>
</xs:extension>
</xs:complexContent>
</xs:complexType>
...
<xs:complexType name="fmi3MandatorilyTypedArrayableVariable" abstract="true">
<xs:complexContent>
<xs:restriction base="fmi3TypedArrayableVariable">
<xs:sequence>
<xs:element ref="Annotations" minOccurs="0"/>
<xs:group ref="fmi3Dimensions"/>
</xs:sequence>
<xs:attribute name="declaredType" type="xs:normalizedString" use="required"/>
</xs:restriction>
</xs:complexContent>
</xs:complexType>
I'll create a PR...
from fmi-standard.
Related Issues (20)
- fmi2_import_get_variable_has_start(fmi2_import_variable_t*) API is returning zero (0) for Outputs and Global Block Outputs HOT 2
- Define allowed call sequence when terminateSimulation = true HOT 3
- Handling of file access and pathname parameters HOT 1
- Clarify allowed call sequence after fmi3Error has been returned HOT 1
- Bump Reference FMUs submodule to latest version prior to release
- Clarify meaning of DefaultExperiment.stepSize for Model Exchange HOT 1
- Define matching rule "none" in the base FMI standard HOT 1
- Recommend or demand reverse domain notation for TerminalKinds and VariableKinds?
- Backport #1940 to FMI 2.0
- Backport #1941 to FMI 2.0
- Add section on when (not) to use Scheduled Execution
- Clarify what to do if a tool cannot do init iteration, the tool should report that correctly in the modelDescription.xml
- Allow setFloat64() for continuous states in Event Mode if reinit = false
- Clarify which variables can be set in Continuous Time Mode HOT 1
- Clarify naming convention for variable names introduced by layered standards HOT 11
- Formalize naming and capitalization conventions for variables, attributes, elements, and functions HOT 1
- Add statement to forbid changing the modelDescription.xml in v2.0.x Word/PDF document HOT 1
- Clarification on what is meant with " unique on each level" for the "name" attribute of a <Terminal> HOT 3
- Proposal to add the attribute "rotation" to <TerminalGraphicalRepresentation> HOT 2
- Proposal for standardizing `fmiModelDescription` interface HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fmi-standard.