2 Copyright (C) 2012 Modelon AB
4 This program is free software: you can redistribute it and/or modify
5 it under the terms of the BSD style license.
7 This program is distributed in the hope that it will be useful,
8 but WITHOUT ANY WARRANTY; without even the implied warranty of
9 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10 FMILIB_License.txt file for more details.
12 You should have received a copy of the FMILIB_License.txt file
13 along with this program. If not, contact Modelon AB <http://www.modelon.com>.
20 #include "fmi1_import_impl.h"
22 fmi1_import_display_unit_t* fmi1_import_get_type_display_unit(fmi1_import_real_typedef_t* t) {
23 return fmi1_xml_get_type_display_unit(t);
26 size_t fmi1_import_get_type_definition_number(fmi1_import_type_definitions_t* td) {
27 return fmi1_xml_get_type_definition_number(td);
30 fmi1_import_variable_typedef_t* fmi1_import_get_typedef(fmi1_import_type_definitions_t* td, unsigned int index) {
31 return fmi1_xml_get_typedef(td, index);
34 const char* fmi1_import_get_type_name(fmi1_import_variable_typedef_t* t) {
35 return fmi1_xml_get_type_name(t);
38 /* Note that NULL pointer is returned if the attribute is not present in the XML.*/
39 const char* fmi1_import_get_type_description(fmi1_import_variable_typedef_t* t) {
40 return fmi1_xml_get_type_description(t);
43 fmi1_base_type_enu_t fmi1_import_get_base_type(fmi1_import_variable_typedef_t* t) {
44 return fmi1_xml_get_base_type(t);
47 fmi1_import_real_typedef_t* fmi1_import_get_type_as_real(fmi1_import_variable_typedef_t* t) {
48 return fmi1_xml_get_type_as_real(t);
51 fmi1_import_integer_typedef_t* fmi1_import_get_type_as_int(fmi1_import_variable_typedef_t* t) {
52 return fmi1_xml_get_type_as_int(t);
55 fmi1_import_enumeration_typedef_t* fmi1_import_get_type_as_enum(fmi1_import_variable_typedef_t* t) {
56 return fmi1_xml_get_type_as_enum(t);
59 /* Note that 0-pointer is returned for strings and booleans, empty string quantity if not defined*/
60 const char* fmi1_import_get_type_quantity(fmi1_import_variable_typedef_t* t) {
61 return fmi1_xml_get_type_quantity(t);
64 fmi1_real_t fmi1_import_get_real_type_min(fmi1_import_real_typedef_t* t) {
65 return fmi1_xml_get_real_type_min(t);
68 fmi1_real_t fmi1_import_get_real_type_max(fmi1_import_real_typedef_t* t) {
69 return fmi1_xml_get_real_type_max(t);
72 fmi1_real_t fmi1_import_get_real_type_nominal(fmi1_import_real_typedef_t* t) {
73 return fmi1_xml_get_real_type_nominal(t);
76 fmi1_import_unit_t* fmi1_import_get_real_type_unit(fmi1_import_real_typedef_t* t) {
77 return fmi1_xml_get_real_type_unit(t);
80 int fmi1_import_get_real_type_is_relative_quantity(fmi1_import_real_typedef_t* t) {
81 return fmi1_xml_get_real_type_is_relative_quantity(t);
84 fmi1_integer_t fmi1_import_get_integer_type_min(fmi1_import_integer_typedef_t* t) {
85 return fmi1_xml_get_integer_type_min(t);
88 fmi1_integer_t fmi1_import_get_integer_type_max(fmi1_import_integer_typedef_t* t){
89 return fmi1_xml_get_integer_type_max(t);
92 unsigned int fmi1_import_get_enum_type_min(fmi1_import_enumeration_typedef_t* t){
93 return fmi1_xml_get_enum_type_min(t);
96 unsigned int fmi1_import_get_enum_type_max(fmi1_import_enumeration_typedef_t* t){
97 return fmi1_xml_get_enum_type_max(t);
100 unsigned int fmi1_import_get_enum_type_size(fmi1_import_enumeration_typedef_t* t) {
101 return fmi1_xml_get_enum_type_size(t);
104 const char* fmi1_import_get_enum_type_item_name(fmi1_import_enumeration_typedef_t* t, unsigned int item) {
105 return fmi1_xml_get_enum_type_item_name(t, item);
108 const char* fmi1_import_get_enum_type_item_description(fmi1_import_enumeration_typedef_t* t, unsigned int item){
109 return fmi1_xml_get_enum_type_item_description(t, item);