v_handle

v_handle#

Purpose

Description

Class constructor for variable handle objects.

v_handle

The Structural Dynamics Toolbox supports variable handle objects, which act as pointers to variables that are actually stored as

  • uo user data of graphical objects (init with v_handle('uo',go)). This is in particular used in feplot to store the model in cf.mdl. For easier access, the format v_handle('uo',parent,'tag','TipCh') allows search by tag and possible creation as a invisible uicontrol.

    It is possible to associate a callback executed when the variable is modified using v_handle('uo',go,SetFcn)

  • so reference to another (stored) object.
  • mat data in files. This latter application may become very useful when handling very large models. sdthdf indeed allows RAM unloading by keeping data on drive while using a pointed to it. A trade-off between data access performance (limited to your drive I/O performance) and amount of free memory will occur. Some supported file formats are MATLAB 6 .mat files (use v_handle('mat','varname','filename')), NASTRAN .op2,op4 (see nasread), ABAQUS .fil ...

    For data in files, methods of interest are extraction def(rows,cols), total read def.GetData or def(:,:), and matrix multiplication c*def.

  • hdf data in MATLAB >7.3 HDF based .mat files (see sdthdf hdfReadRef)
  • base global variables (init with v_handle('global','name')), use is discontinued
  • mkls 32 bit sparse (init with v_handle('mkls',k)) used for improved time response

v_handle objects essentially behave like global variables with the notable exception that a clear command only deletes the handle and not the pointed data.

Only advanced programmers should really need access to the internal structure of v_handle.