Determine if System object is in use
The object performs an internal initialization the first time that you call the object. After initialization, the object is
considered in-use and you cannot change nontunable properties and other specifications determined by the System
object author. While an object is in use,
true). To allow changes to the object, call
Counter object and set a property.
obj = Counter; obj.UseIncrement = false
obj = Counter with properties: UseIncrement: 0 UseWrapValue: 1 StartValue: 1 Increment: 1 WrapValue: 10
Call the object.
ans = 2
Check if the object is in use.
ans = logical 1
Release the object and check if the object is still locked.
ans = logical 0
obj— System object™ to query
System object whose status you want to query.
tf— True or false
True or false result, returned as logical
0 indicating the status of the
System object as in use (locked) or not.
For details, see System Objects in MATLAB Code Generation (MATLAB Coder).