Derive classes from built-in classes to define specialized data types that extend the operations you can perform on a particular class of data. The subclass inherits the built-in class methods and behaviors and can add new methods to perform specialized operations.
Heterogeneous class hierarchies enable you to form arrays of different, but related classes.
Extend MATLAB® built-in classes by deriving from these fundamental data types.
Subclass built-in classes to extend the behavior of functions that operate on that type of data.
numel functions work with user-defined class.
Class can derive from a built-in class without defining properties and new behaviors.
Classes that derive from built-in classes and define properties must define array behaviors for those classes.
This example of a class derived from a built-in numeric class inherits useful behaviors.
Enumeration classes derived from built-in types inherit behaviors from these types.