Home > functions > gui > batch > batch_parm_set > vb_batch_parm_set_get_parm.m

vb_batch_parm_set_get_parm

PURPOSE ^

Return the parameter and type.

SYNOPSIS ^

function [parm, parm_type] = vb_batch_parm_set_get_parm(obj, ix)

DESCRIPTION ^

 Return the parameter and type.

 [USAGE]
    [parm, parm_type] = vb_batch_parm_set_get_parm(<obj>, <ix>);
 [IN]
    obj : vb_batch_parm_set object
     ix : index of this parameter set.
 [OUT]
         parm : parameter
    parm_type : parameter type

 Copyright (C) 2011, ATR All Rights Reserved.
 License : New BSD License(see VBMEG_LICENSE.txt)

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function [parm, parm_type] = vb_batch_parm_set_get_parm(obj, ix)
0002 % Return the parameter and type.
0003 %
0004 % [USAGE]
0005 %    [parm, parm_type] = vb_batch_parm_set_get_parm(<obj>, <ix>);
0006 % [IN]
0007 %    obj : vb_batch_parm_set object
0008 %     ix : index of this parameter set.
0009 % [OUT]
0010 %         parm : parameter
0011 %    parm_type : parameter type
0012 %
0013 % Copyright (C) 2011, ATR All Rights Reserved.
0014 % License : New BSD License(see VBMEG_LICENSE.txt)
0015 
0016 %
0017 % --- Previous check
0018 %
0019 if ~exist('obj', 'var')
0020     error('obj is a required parameter.');
0021 end
0022 if ~exist('ix', 'var')
0023     error('ix is a required parameter.');
0024 end
0025 
0026 %
0027 % --- Main Procedure
0028 %
0029 parm = [];
0030 parm_type = [];
0031 try
0032     if isempty(ix), return; end
0033     parm      = obj.list{ix, 1};
0034     parm_type = obj.list{ix, 2};
0035 catch
0036     warning('specified index is invalid.');
0037 end

Generated on Tue 27-Aug-2013 11:46:04 by m2html © 2005