-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdata_representation.m
42 lines (36 loc) · 1.23 KB
/
data_representation.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
classdef data_representation < handle
%TAG Groups together some commmon attributes of trajectories
properties(GetAccess = 'public', SetAccess = 'protected')
% short and long descriptions
data_type = 0;
end
properties(GetAccess = 'private', SetAccess = 'private')
hash_ = [];
f_ = [];
end
methods
%% constructor
function inst = data_representation(desc, data_type, func, rarg, prop, varargin)
inst.data_type = data_type;
if nargin < 4
rarg = 1;
end
if nargin < 5
prop = {};
end
inst.f_ = function_wrapper(desc, func, rarg, prop, varargin{:});
end
function val = hash_value(inst)
val = inst.f_.hash_value;
end
function set_parameters(inst, config)
inst.f_.set_parameters(config);
end
function ret = apply(inst, traj, varargin)
ret = inst.f_.apply1(traj, varargin{:});
end
function desc = description(inst)
desc = inst.f_.description;
end
end
end