Package: matlab.unittest.constraints
Comparator for public properties of MATLAB objects
The PublicPropertyComparator
compares public
properties of MATLAB® objects.
The PublicPropertyComparator
supports MATLAB objects
or arrays of objects and recursively compares data structures contained
in the public properties. The PublicPropertyComparator
is
different from the isequal
function because it
examines only the public properties of the objects.
Typically you construct a PublicPropertyComparator
using
the supportingAllValues
static
method.
PublicPropertyComparator
creates a comparator
for public properties of MATLAB objects. This comparator supports
only objects with no public properties.
PublicPropertyComparator(
indicates
a comparator, compObj
)compObj
, that defines the comparator
used to compare public properties. This comparator supports recursion
only in the data types supported by compObj
.
PublicPropertyComparator(
provides
a comparator with additional options specified by one or more compObj
,Name,Value
)Name,Value
pair
arguments.
supportingAllValues | Comparator for public properties that supports any value in recursion |
|
Properties to ignore during object comparison, specified in
the name-value pair argument, |
|
Indicator of whether comparator operates recursively, specified
in the name-value pair argument, |
The PublicPropertyComparator
does not
compare public properties of objects that overload the subsref
, numel
,
or properties
functions.
Value. To learn how value classes affect copy operations, see Copying Objects.