Index: client/html/src/Float64ArrayWrappingImplementation.dart |
diff --git a/client/html/generated/src/wrapping/_Float64ArrayWrappingImplementation.dart b/client/html/src/Float64ArrayWrappingImplementation.dart |
similarity index 54% |
rename from client/html/generated/src/wrapping/_Float64ArrayWrappingImplementation.dart |
rename to client/html/src/Float64ArrayWrappingImplementation.dart |
index bc7430ae0b05e1c7eeb5109fcd3f11bbf4aa8f76..4690018052776fda8f1ed0b8d907c9d8e6348fa6 100644 |
--- a/client/html/generated/src/wrapping/_Float64ArrayWrappingImplementation.dart |
+++ b/client/html/src/Float64ArrayWrappingImplementation.dart |
@@ -2,11 +2,21 @@ |
// for details. All rights reserved. Use of this source code is governed by a |
// BSD-style license that can be found in the LICENSE file. |
-// WARNING: Do not edit - generated code. |
- |
class Float64ArrayWrappingImplementation extends ArrayBufferViewWrappingImplementation implements Float64Array { |
Float64ArrayWrappingImplementation._wrap(ptr) : super._wrap(ptr) {} |
+ factory Float64ArrayWrappingImplementation(int length) => |
+ LevelDom.wrapFloat64Array(new dom.Float64Array(length)); |
+ |
+ factory Float64ArrayWrappingImplementation.from(List<num> list) => |
+ // TODO(nweiz): when there's a cross-platform name for the native |
+ // implementation of List, check if [list] is native and if not convert it |
+ // to a native list before sending it to the JS constructor. |
+ LevelDom.wrapFloat64Array(new dom.Float64Array.fromList(list)); |
+ |
+ factory Float64ArrayWrappingImplementation.fromBuffer(ArrayBuffer buffer) => |
+ LevelDom.wrapFloat64Array(new dom.Float64Array.fromBuffer(LevelDom.unwrap(buffer))); |
+ |
int get length() { return _ptr.length; } |
Float64Array subarray(int start, [int end]) { |