You can define datetime
array inputs at the
command line. Programmatic specification of datetime
input types by using
preconditioning (assert
statements) is not supported.
Use one of these procedures:
Alternatively, if you have a test file that calls your entry-point function with example
inputs, you can determine the input types by using
coder.getArgTypes
.
Use the -args
option:
D = datetime(2019,1:12,1,12,0,0); fiaccel myFunction -args {D}
To provide a type for a datetime
array to fiaccel
:
Define a datetime
array. For
example:
D = datetime(2019,1:12,1,12,0,0);
Create a type from
D
.
t = coder.typeof(D);
Pass the type to fiaccel
by using the
-args
option.
fiaccel myFunction -args {t}
To specify that a datetime
array input is constant, use
coder.Constant
with the -args
option:
D = datetime(2019,1:12,1,12,0,0); fiaccel myFunction -args {coder.Constant(C)}
datetime
| NaT
| coder.Constant
(MATLAB Coder) | coder.typeof
(MATLAB Coder)