// Copyright 2017-2018 Alexander Luzgarev using System; namespace MatFileHandler { /// /// Type of a Matlab array. /// internal enum ArrayType { /// /// Cell array. /// MxCell = 1, /// /// Structure array. /// MxStruct = 2, /// /// Matlab object. /// MxObject = 3, /// /// Character array. /// MxChar = 4, /// /// Sparse array. /// MxSparse = 5, /// /// Double array. /// MxDouble = 6, /// /// Single array. /// MxSingle = 7, /// /// Int8 array. /// MxInt8 = 8, /// /// UInt8 array. /// MxUInt8 = 9, /// /// Int16 array. /// MxInt16 = 10, /// /// UInt16 array. /// MxUInt16 = 11, /// /// Int32 array. /// MxInt32 = 12, /// /// UInt32 array. /// MxUInt32 = 13, /// /// Int64 array. /// MxInt64 = 14, /// /// UInt64 array. /// MxUInt64 = 15, /// /// Undocumented opaque object type. /// MxOpaque = 17, } /// /// Variable flags. /// [Flags] internal enum Variable { /// /// Indicates a logical array. /// IsLogical = 2, /// /// Indicates a global variable. /// IsGlobal = 4, /// /// Indicates a complex array. /// IsComplex = 8, } /// /// Array properties. /// internal struct ArrayFlags { /// /// Array type. /// public ArrayType Class; /// /// Variable flags. /// public Variable Variable; /// /// Initializes a new instance of the struct. /// /// Array type. /// Variable flags. public ArrayFlags(ArrayType class_, Variable variable) { Class = class_; Variable = variable; } } /// /// Sparse array properties. /// internal struct SparseArrayFlags { /// /// Usual array properties. /// public ArrayFlags ArrayFlags; /// /// Maximal number of non-zero elements. /// public uint NzMax; } }