www.gusucode.com > mbc 工具箱 matlab 源码程序 > mbc/@xregpointer/vertcat.m
function q=vertcat(varargin) %VERTCAT vertical concatenation of pointers % % S = [P;Q] concatenates pointer arrays P and Q vertically. % % Copyright 2000-2005 The MathWorks, Inc. and Ford Global Technologies, Inc. isemp= cellfun('isempty',varargin); list= varargin(~isemp); q = list{1}; if ~isa(q,'xregpointer') error(message('mbc:xregpointer:InvalidArgument')) end for i=2:length(list) p= list{i}; if isa(p,'xregpointer') q.ptr= [q.ptr ; p.ptr]; elseif isa(p,'double') && all( p(:)==0 ) q.ptr= [q.ptr ; p]; else error(message('mbc:xregpointer:InvalidArgument')) end end