Tagged: Subclasses

Comparing Handle and Value Classes

Why Select Handle or Value MATLAB support two kinds of classes — handle classes and value classes. The kind of class you use depends on the desired behavior of the class instances and what...

Specifying Class Precedence

InferiorClasses Attribute You can specify the relative precedence of user-defined classes using the class InferiorClasses attribute. Assign a cell array of class names (represented as meta.class objects) to this attribute to specify classes that...

Calling Superclass Methods on Subclass Objects

Calling a Superclass Constructor If you create a subclass object, MATLAB calls the superclass constructor to initialize the superclass part of the subclass object. By default, MATLAB calls the superclass constructor without arguments. If...

Matlab Class Definition & The Classdef Block

Specifying Attributes and Superclasses The classdef block contains the class definition. The classdef line is where you specify: Class attributes Superclasses The classdef block contains the properties, methods, and events subblocks. Assigning Class Attributes...