The function returns the absolute path of a
uniform resource identifier (URI) or local file name.
If the file is not found, then this function
terminates with an assert
.
This function has been introduced to allow users to specify the name of weather data files with a path that is relative to the library path. This allows users to change the current working directory while still being able to read the files.
pure function getAbsolutePath extends Modelica.Icons.Function; input String uri "A URI"; output String path "The absolute path of the file pointed to by the URI"; end getAbsolutePath;
Modelica.Utilities.Files.fullPathName
which is implicitly done in Modelica.Utilities.Files.loadResource
. file://
to file names which do not start
with file://
, or modelica://
.
This is not required when using Modelica.Utilities.Files.loadResource
.
ModelicaServices.ExternalReferences.loadResource
with
Modelica.Utilities.Files.loadResource
.
AixLib
library
is on the MODELICAPATH
.