MATLAB Object-Oriented Programming

(Joyce) #1

Property Syntax


In this section...
“Property Definition Block” on page 8-5
“Access Property Values” on page 8-6
“Inheritance of Properties” on page 8-7
“Specify Property Attributes” on page 8-7

Property Definition Block


The following illustration shows a typical property specification. The properties and
end keywords delineate a block of code that defines properties having the same attribute
settings.

Property name

properties block

properties keyword begins de!nition block.

end keyword terminates de!nition block.

properties


Coefficients = [0 0 1]


end


Default value

(SetAccess = protected)


Attribute speci!cation

NoteProperties cannot have the same name as the class.

Property Syntax
Free download pdf