www.gusucode.com > mbcview 工具箱matlab源码程序 > mbcview/@cgtradeoffgui/@tradeoffExecutor/saveValues.m

    function saveValues(obj)
%SAVEVALUES Save the candidate input values
%
%  SAVEVALUES(OBJ) applies the current candidate values for the tradeoff to
%  the inputs and saves them for the current tradeoff point.

%  Copyright 2000-2004 The MathWorks, Inc. and Ford Global Technologies, Inc.


pTO = obj.hMessageService.CurrentTradeoff;
if ~isempty(pTO)
    % Snap all inputs to their current point values
    obj.setPointValues;

    % Use the most recent index type as indicator of reliable, valid index
    if strcmp(obj.hMessageService.LastIndexType, 'list')
        pTO.captureInputsAt('list', obj.hMessageService.CurrentListIndex);
    else
        pTO.captureInputsAt('table', obj.hMessageService.CurrentTableIndex{:});
    end
    obj.hMessageService.notifySavedValueChange;
end