coder.PrimitiveType Class
Namespace: coder
Superclasses: coder.ArrayType
Represent set of logical, numeric, or character arrays acceptable for input specification
Description
Objects of coder.PrimitiveType
specify logical, numeric, or character
values that the generated code accepts. Supported types are half
,
double
, single
, int8
,
uint8
, int16
, uint16
,
int32
, uint32
, int64
,
uint64
, char
, and logical
. Use
objects of this class only with the -args
option of the fiaccel
command. Do not pass as an input to a generated MEX function.
Creation
creates
a t
= coder.typeof(v
)coder.PrimitiveType
object denoting the smallest
non-constant type that contains v
. v
must be a
MATLAB® numeric, logical or character.
creates a t
= coder.typeof(v
,sz
,variableDims
)coder.PrimitiveType
object with upper bound sizes specified by
sz
and variable dimensions indicated in variableDims
.
If sz
specifies Inf
for a dimension, then the size of
the dimension is unbounded and variable sized. When sz
is
[]
, the upper bound sizes of v
remain unchanged. If
you do not specify the variableDims
, the bounded dimensions of the type are
fixed. When variableDims
is a scalar, this function applies this value to
the bounded dimensions that are not 1
or 0
, which are
fixed.
creates a t
= coder.newtype(numericClass
,sz
,variableDims
)coder.PrimitiveType
object representing values of
class numericClass
with upper bound sizes sz
and
variable dimensions indicated in variableDims
. If sz
specifies Inf
for a dimension, then the size of the dimension is unbounded
and variable sized. If you do not specify the variableDims
, the bounded
dimensions of the type are fixed. When variableDims
is a scalar, this
function applies this value to the bounded dimensions that are not 1
or
0
, which are fixed.
creates a t
= coder.newtype(numericClass
,sz
,variableDims
,Name=Value)coder.PrimitiveType
object with additional options
specified by one or more name,-value arguments. Name
is a property name and
Value
is the corresponding value. Specify Name
as
character vector or string scalar. You can specify several name-value arguments in
any order as
Name1=Value1,…,NameN=ValueN
.
Note
You can create and edit coder.Type
objects interactively by using the
Coder Type Editor. See Create and Edit Input Types by Using the Coder Type Editor.
Input Arguments
Properties
Examples
Version History
Introduced in R2011a
See Also
coder.ClassType
(MATLAB Coder) | coder.Type
| coder.ArrayType
| coder.newtype
| coder.typeof
| coder.resize
| fiaccel