rbmatlab  1.16.09
 All Classes Namespaces Files Functions Variables Modules Pages
StokesReducedDataWrapper.m
1 classdef StokesReducedDataWrapper < handle
2 %classdef StokesReducedDataWrapper < handle
3 % Wrapper-class for reduced data containing big data
4 
5  properties (Access=private,Hidden=true)
6  reduced_data
7  end
8 
9  methods
10 
11  % simple constructor
12  function this = StokesReducedDataWrapper(reduced_data)
13  this.reduced_data = reduced_data;
14  end
15 
16  % set reduced_data
17  function set(this, reduced_data)
18  this.reduced_data = reduced_data;
19  end
20 
21  % get reduced_data
22  function reduced_data = get(this)
23  reduced_data = this.reduced_data;
24  end
25 
26  % forward to reduced_data
27  function b = isempty(this)
28  b = isempty(this.reduced_data);
29  end
30 
31  % forward to reduced_data
32  function b = isfield(this, fieldnames)
33  b = isfield(this.reduced_data, fieldnames);
34  end
35 
36  % conditionally forward to reduced_data
37  function varargout = subsref(this, S)
38  if any(strcmp(S(1).subs, methods(this)))
39  [varargout{1:nargout}] = builtin('subsref', this, S);
40  else
41  [varargout{1:nargout}] = subsref(this.reduced_data, S);
42  end
43  end
44 
45  % conditionally forward to reduced_data
46  function this = subsasgn(this, S, B)
47  if any(strcmp(S(1).subs, methods(this)))
48  this = builtin('subsasgn', this, S, B);
49  else
50  this.reduced_data = subsasgn(this.reduced_data, S, B);
51  end
52  end
53  end
54 
55 end
Wrapper-class for reduced data containing big data.