private static Array ExtractArrayValue(ArrayType openType, string[] value) { var objectArray = value.Select(x => ExtractSimpleValue(openType.ElementType, x)).ToArray(); var typedArray = Array.CreateInstance(openType.ElementType.Representation, objectArray.Length); Array.Copy(objectArray, typedArray, objectArray.Length); return typedArray; }
public ArrayDataType_Type(ArrayType value) : base(value) { dimension = value.Dimension; dimensionSpecified = true; ElementType = Serialize(value.ElementType); }
public SampleDynamicMBean() { _rowType = new CompositeType("Row", "Row", new[] { "ID", "Name" }, new[] { "Unique ID", "Name" }, new[] { SimpleType.Integer, SimpleType.String }); _tabularType = new TabularType("Table", "Table", _rowType, new[] { "ID" }); _tabularValue = new TabularDataSupport(_tabularType); _arrayType = new ArrayType(1, SimpleType.Decimal); }