MCPcopy Create free account
hub / github.com/NativeScript/android / GetCastType

Function GetCastType

test-app/runtime/src/main/cpp/conversions/CastTypes.h:17–30  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

15 };
16
17 tns::JavaObjectCastType GetCastType(const v8::Local <v8::ArrayBufferView> &view) {
18 if (view->IsUint16Array() || view->IsInt16Array()) {
19 return tns::JavaObjectCastType::Short;
20 } else if (view->IsUint32Array() || view->IsInt32Array()) {
21 return tns::JavaObjectCastType::Int;
22 } else if (view->IsFloat32Array()) {
23 return tns::JavaObjectCastType::Float;
24 } else if (view->IsFloat64Array()) {
25 return tns::JavaObjectCastType::Double;
26 } else if (view->IsBigUint64Array() || view->IsBigInt64Array()) {
27 return tns::JavaObjectCastType::Long;
28 }
29 return tns::JavaObjectCastType::Byte;
30 }
31
32}
33

Callers 4

ConvertArgMethod · 0.85
GetTypeMethod · 0.85
ConvertArgMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected