Ignore:
Timestamp:
11/29/11 19:29:01 (13 years ago)
Author:
Eric.Larour
Message:

merged trunk-jpl and trunk for revision 10980

Location:
issm/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk

  • issm/trunk/src/m/classes/settings.m

    r9862 r10981  
    66classdef settings
    77        properties (SetAccess=public)
    8                 io_gather           = modelfield('default',0,'marshall',true,'format','Boolean');
    9                 lowmem              = modelfield('default',0,'marshall',true,'format','Boolean');
    10                 results_on_vertices = modelfield('default',0,'marshall',true,'format','Boolean');
    11                 output_frequency    = modelfield('default',0,'marshall',true,'format','Integer');
    12                 waitonlock          = modelfield('default',0,'marshall',true,'format','Boolean');
     8                io_gather           = 0;
     9                lowmem              = 0;
     10                results_as_patches  = 0;
     11                output_frequency    = 0;
     12                waitonlock          = 0;
    1313        end
    1414        methods
     
    3030                function obj = setdefaultparameters(obj) % {{{
    3131
    32                         %first, use the defaults provided by the properties definition above.
    33                         fieldnames=fields(obj);
    34                         for i=1:length(fieldnames),
    35                                 fieldname=fieldnames{i};
    36                                 obj.(fieldname)=obj.(fieldname).default;
    37                         end
    38 
    3932                        %are we short in memory ? (0 faster but requires more memory)
    4033                        obj.lowmem=0;
     
    4538                        %results frequency by default every step
    4639                        obj.output_frequency=1;
     40
     41                        %do not use patches by default (difficult to plot)
     42                        obj.results_as_patches=0;
    4743
    4844                        %this option can be activated to load automatically the results
     
    5652                        checkfield(md,'settings.io_gather','numel',1,'values',[0 1]);
    5753                        checkfield(md,'settings.lowmem','numel',1,'values',[0 1]);
    58                         checkfield(md,'settings.results_on_vertices','numel',1,'values',[0 1]);
     54                        checkfield(md,'settings.results_as_patches','numel',1,'values',[0 1]);
    5955                        checkfield(md,'settings.output_frequency','numel',1,'>=',1);
    6056                        checkfield(md,'settings.waitonlock','numel',1);
     
    6662                        fielddisplay(obj,'io_gather','I/O gathering strategy for result outputs (default 1)');
    6763                        fielddisplay(obj,'lowmem','is the memory limited ? (0 or 1)');
    68                         fielddisplay(obj,'results_on_vertices','provide results on vertices instead of patch (0 or 1)');
     64                        fielddisplay(obj,'results_as_patches','provide results as patches for each element (0 or 1)');
    6965                        fielddisplay(obj,'output_frequency','frequency at which results are saved in all solutions with multiple time_steps');
    7066                        fielddisplay(obj,'waitonlock','maximum number of minutes to wait for batch results, or return 0');
    7167
    7268                end % }}}
     69                function marshall(obj,fid) % {{{
     70                        WriteData(fid,'object',obj,'fieldname','io_gather','format','Boolean');
     71                        WriteData(fid,'object',obj,'fieldname','lowmem','format','Boolean');
     72                        WriteData(fid,'object',obj,'fieldname','results_as_patches','format','Boolean');
     73                        WriteData(fid,'object',obj,'fieldname','output_frequency','format','Integer');
     74                        WriteData(fid,'object',obj,'fieldname','waitonlock','format','Boolean');
     75                end % }}}
    7376        end
    7477end
Note: See TracChangeset for help on using the changeset viewer.