| 470 | class VectorViewWrapper : NodeRT::WrapperBase { |
| 471 | public: |
| 472 | static void Init() { |
| 473 | HandleScope scope; |
| 474 | |
| 475 | Local<FunctionTemplate> localRef = Nan::New<FunctionTemplate>(New); |
| 476 | s_constructorTemplate.Reset(localRef); |
| 477 | localRef->SetClassName( |
| 478 | Nan::New<String>("Windows::Foundation::Collections:IVectorView") |
| 479 | .ToLocalChecked()); |
| 480 | localRef->InstanceTemplate()->SetInternalFieldCount(1); |
| 481 | Nan::SetIndexedPropertyHandler(localRef->InstanceTemplate(), Get); |
| 482 | |
| 483 | Nan::SetPrototypeMethod(localRef, "getMany", GetMany); |
| 484 | Nan::SetPrototypeMethod(localRef, "getAt", GetAt); |
| 485 | Nan::SetPrototypeMethod(localRef, "indexOf", IndexOf); |
| 486 | Nan::SetPrototypeMethod(localRef, "first", First); |
| 487 | |
| 488 | Nan::SetAccessor(localRef->PrototypeTemplate(), |
| 489 | Nan::New<String>("size").ToLocalChecked(), SizeGetter); |
| 490 | Nan::SetAccessor(localRef->PrototypeTemplate(), |
| 491 | Nan::New<String>("length").ToLocalChecked(), SizeGetter); |
| 492 | |
| 493 | return; |
| 494 | } |
| 495 | |
| 496 | static Local<Value> CreateVectorViewWrapper( |
| 497 | ::Windows::Foundation::Collections::IVectorView<T> ^ winRtInstance, |
nothing calls this directly
no outgoing calls
no test coverage detected