Home > classes > @ltpda_obj > ltpda_obj.m

ltpda_obj

PURPOSE ^

LTPDA_OBJ is the abstract ltpda base class.

SYNOPSIS ^

This is a script file.

DESCRIPTION ^

 LTPDA_OBJ is the abstract ltpda base class.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

 DESCRIPTION:   LTPDA_OBJ is the ltpda base class.
                This ltpda_obj class is an abstract class and it is
                not possible to create an instance of this class.

 SUPER CLASSES: handle (MATLAB class)

 SUB CLASSES:   ltpda_nuc, ltpda_uc

 PROPERTIES:

     Protected Properties (read only)
       version          - cvs-version string.

 LTPDA_OBJ METHODS:

     Public Methods:
       eq               - equal operator for ltpda objects.
       isprop           - tests if the given field is one of the object properties.
       ne               - not equal operator for ltpda objects.

     Protected Methods:
       setVersion       - set the property 'version'
       prependVersion   - prepend the version string

     Abstract Methods:
       char             - returns one character string which represents the object
       copy             - copies an object
       display          - displays an object
       update_struct    - updates a object structure to the current tbx-version

 REMARK:      It is necessary to define the ABSTRACT methods and properties in the
              sub-classes because if they are not defined is the sub-class as well
              an abstract class. (See ltpda_nuo)

 M-FILE INFO: The following call returns an minfo object that contains
              information about the ltpda_obj constructor:
                   >> info = ltpda_obj.getInfo
              or   >> info = ltpda_obj.getInfo('ltpda_obj')

 VERSION:     $Id: ltpda_obj.m,v 1.20 2008/08/20 09:13:31 ingo Exp $

 HISTORY:     19-05-2008 Diepholz
                 Creation.

 SEE ALSO:    ltpda_nuo, ltpda_uo, handle

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SUBFUNCTIONS ^

SOURCE CODE ^

0001 % LTPDA_OBJ is the abstract ltpda base class.
0002 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0003 %
0004 % DESCRIPTION:   LTPDA_OBJ is the ltpda base class.
0005 %                This ltpda_obj class is an abstract class and it is
0006 %                not possible to create an instance of this class.
0007 %
0008 % SUPER CLASSES: handle (MATLAB class)
0009 %
0010 % SUB CLASSES:   ltpda_nuc, ltpda_uc
0011 %
0012 % PROPERTIES:
0013 %
0014 %     Protected Properties (read only)
0015 %       version          - cvs-version string.
0016 %
0017 % LTPDA_OBJ METHODS:
0018 %
0019 %     Public Methods:
0020 %       eq               - equal operator for ltpda objects.
0021 %       isprop           - tests if the given field is one of the object properties.
0022 %       ne               - not equal operator for ltpda objects.
0023 %
0024 %     Protected Methods:
0025 %       setVersion       - set the property 'version'
0026 %       prependVersion   - prepend the version string
0027 %
0028 %     Abstract Methods:
0029 %       char             - returns one character string which represents the object
0030 %       copy             - copies an object
0031 %       display          - displays an object
0032 %       update_struct    - updates a object structure to the current tbx-version
0033 %
0034 % REMARK:      It is necessary to define the ABSTRACT methods and properties in the
0035 %              sub-classes because if they are not defined is the sub-class as well
0036 %              an abstract class. (See ltpda_nuo)
0037 %
0038 % M-FILE INFO: The following call returns an minfo object that contains
0039 %              information about the ltpda_obj constructor:
0040 %                   >> info = ltpda_obj.getInfo
0041 %              or   >> info = ltpda_obj.getInfo('ltpda_obj')
0042 %
0043 % VERSION:     $Id: ltpda_obj.m,v 1.20 2008/08/20 09:13:31 ingo Exp $
0044 %
0045 % HISTORY:     19-05-2008 Diepholz
0046 %                 Creation.
0047 %
0048 % SEE ALSO:    ltpda_nuo, ltpda_uo, handle
0049 %
0050 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0051 
0052 classdef ltpda_obj < handle
0053 
0054   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0055   %                            Property definition                            %
0056   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0057 
0058   %---------- Public (read/write) Properties  ----------
0059   properties
0060   end
0061 
0062   %---------- Protected read-only Properties ----------
0063   properties (SetAccess = protected)
0064     version = '';
0065   end
0066 
0067   %---------- Abstract Properties ----------
0068   properties (Abstract = true, SetAccess = protected)
0069   end
0070 
0071   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0072   %                          Check property setting                           %
0073   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0074 
0075   methods
0076     function obj = set.version(obj, val)
0077       if ~ischar(val) || isempty(val)
0078         error('### The value for the property ''version'' must be a non-empty string');
0079       else
0080         obj.version = val;
0081       end
0082     end
0083   end
0084 
0085   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0086   %                                Constructor                                %
0087   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0088 
0089   methods
0090     function obj = ltpda_obj(varargin)
0091 
0092       %%%%%%%%%%   Set dafault values   %%%%%%%%%%
0093       obj.version = '$Id: ltpda_obj.m,v 1.20 2008/08/20 09:13:31 ingo Exp $';
0094 
0095       if nargin == 1
0096 
0097         if isstruct(varargin{1})
0098           %%%%%%%%%%   obj = ltpda_uo(struct)   %%%%%%%%%%
0099           %%% Set properties which are declared in this class
0100           obj.version = varargin{1}.version;
0101         end
0102 
0103       end
0104 
0105     end
0106   end
0107 
0108   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0109   %                              Methods (public)                             %
0110   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0111 
0112   methods (Access = public)
0113     result    = eq(obj1, obj2, varargin)
0114     result    = ne(obj1, obj2, varargin)
0115     varargout = isprop(varargin)
0116   end
0117 
0118   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0119   %                             Methods (protected)                           %
0120   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0121 
0122   methods (Access = protected)
0123     obj = prependVersion(obj, val)
0124     obj = setVersion(obj, val)
0125   end
0126 
0127   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0128   %                              Methods (static)                             %
0129   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0130 
0131   methods (Static)
0132 
0133     function ii = getInfo(varargin)
0134       ii = utils.helper.generic_getInfo(varargin{:}, 'ltpda_obj');
0135     end
0136 
0137     function out = VEROUT()
0138       out = '$Id: ltpda_obj.m,v 1.20 2008/08/20 09:13:31 ingo Exp $';
0139     end
0140 
0141     function out = SETS()
0142       out = {};
0143     end
0144 
0145     function out = getDefaultPlist()
0146       out = [];
0147     end
0148 
0149   end
0150 
0151   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0152   %                              Methods (abstract)                           %
0153   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0154 
0155   methods (Abstract)
0156     varargout = char(varargin)
0157     varargout = copy(varargin)
0158     txt       = display(varargin)
0159   end
0160   
0161   methods (Abstract = true, Static = true)
0162     varargout = update_struct(varargin);
0163   end
0164 
0165 end
0166

Generated on Mon 25-Aug-2008 22:39:29 by m2html © 2003