MATLAB Function Reference Previous page   Next Page
set (timer)

Configure or display timer object properties

Syntax

Description

set(obj) displays property names and their possible values for all configurable properties of timer object obj. obj must be a single timer object.

prop_struct = set(obj) returns the property names and their possible values for all configurable properties of timer object obj. obj must be a single timer object. The return value, prop_struct, is a structure whose field names are the property names of obj, and whose values are cell arrays of possible property values or empty cell arrays if the property does not have a finite set of possible string values.

set(obj,'PropertyName') displays the possible values for the specified property, PropertyName, of timer object obj. obj must be a single timer object.

prop_cell=set(obj,'PropertyName') returns the possible values for the specified property, PropertyName, of timer object obj. obj must be a single timer object. The returned array, prop_cell, is a cell array of possible value strings or an empty cell array if the property does not have a finite set of possible string values.

set(obj,'PropertyName',PropertyValue,...) configures the property, PropertyName, to the specified value, PropertyValue, for timer object obj. You can specify multiple property name/property value pairs in a single statement. obj can be a single timer object or a vector of timer objects, in which case set configures the property values for all the timer objects specified.

set(obj,S) configures the properties of obj, with the values specified in S, where S is a structure whose field names are object property names.

set(obj,PN,PV) configures the properties specified in the cell array of strings, PN, to the corresponding values in the cell array PV, for the timer object obj. PN must be a vector. If obj is an array of timer objects, PV can be an M-by-N cell array, where M is equal to the length of timer object array and N is equal to the length of PN. In this case, each timer object is updated with a different set of values for the list of property names contained in PN.

Examples

Create a timer object.

Display all configurable properties and their possible values.

View the possible values of the ExecutionMode property.

Set the value of a specific timer object property.

Set the values of several properties of the timer object.

Use a cell array to specify the names of the properties you want to set and another cell array to specify the values of these properties.

See Also

timer, get


Previous page  setstr setxor Next page

© 1994-2005 The MathWorks, Inc.