Skip to content
Snippets Groups Projects
Select Git revision
  • c04a3f8cde9596b8256cd3bb01ee2667bad37a62
  • master default protected
2 results

FT_create_new_block.m

Blame
    • adf's avatar
      ef25ce70
      · ef25ce70
      adf authored
      adding current code of SimTools.
      
      ef25ce70
      History
      adf authored
      adding current code of SimTools.
      
    FT_create_new_block.m 686 B
    %---------------------------------------------------------------------  
    % function [block] = FT_create_new_block(name)
    % 
    % Creates a new 'block' structure.
    %
    % name: string, name of block
    % block: empty block structure
    %
    % Part of the SimTools package
    % Andreas Freise 22.05.08 afreise@googlemail.com
    %---------------------------------------------------------------------  
    
    function [block] = FT_create_new_block(name)
      
      baseid='FT_create_new_block';
      
      if (~isstr(name))
        msgid=[baseid,':checkinarg'];
        result='input argument must be a string';
        error(msgid,result);
      end
      
      block=struct('name',strtrim(name),'filename','','edited',0,'n_lines',0,'txt_lines','');