Favago Transport Programming Interface

Introduction

Interfaces

root/

root/utils

Data structures

Examples







LoadFromFile

  Copyright (C) 2009-2015 Peter Rakyta, Ph.D.
  This program is free software: you can redistribute it and/or modify
  it under the terms of the GNU General Public License as published by
  the Free Software Foundation, either version 3 of the License, or
  (at your option) any later version.
  This program is distributed in the hope that it will be useful,
  but WITHOUT ANY WARRANTY; without even the implied warranty of
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  GNU General Public License for more details.
  You should have received a copy of the GNU General Public License
  along with this program.  If not, see http://www.gnu.org/licenses/.

Description

Returns an interface to load variables from a file.

Syntax

interface = LoadFromFile( filename )

Parameters
filename A string containing the filename.

Attributes

Methods

LoadVariable

LoadFromFile::LoadVariable

Loads a variable from the opened file.

Syntax

ret = interface.LoadVariable( varname )

Parameters
varname The name of the variable.
varargin Optional parameters given by a sequance ...'name', value,... . Possible parameters are the following:
  • NoEmpty

    Set true for throw an error when the loaded variable is empty.
  • StructName

    String containing the name of a structure, when the wanted variable is a field of a loaded structure.

Return
ret The value of the loaded variable.






ClearLoadedVariables

LoadFromFile::ClearLoadedVariables

Disposes the loaded file.

Syntax

interface.ClearLoadedVariables()