LIBRARY LINK 符号

MTensor_getType


gets the type of an MTensor.

更多信息更多信息

  • Used in C/C++ code in a library function called from Mathematica.
  • Returns one of MType_Integer, MType_Real, or MType_Complex.

范例范例打开所有单元关闭所有单元

基本范例 (1)基本范例 (1)

This checks that this is an integer MTensor:

MTensor T0;
mint type;
...
type = libData->MTensor_getType( T0);
if ( type != MType_Integer) {
processError();
}
New to Mathematica? Find your learning path »
Have a question? Ask support »