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

Function buildLogString

test-app/runtime/src/main/cpp/console/Console.cpp:151–172  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

149}
150
151std::string buildLogString(const v8::FunctionCallbackInfo<v8::Value>& info, int startingIndex = 0) {
152 auto isolate = info.GetIsolate();
153 v8::HandleScope scope(isolate);
154 std::stringstream ss;
155
156 auto argLen = info.Length();
157 if (argLen) {
158 for (int i = startingIndex; i < argLen; i++) {
159 // separate args with a space
160 if (i != 0) {
161 ss << " ";
162 }
163
164 std::string argString = buildStringFromArg(isolate, info[i]);
165 ss << argString;
166 }
167 } else {
168 ss << std::endl;
169 }
170
171 return ss.str();
172}
173
174void Console::assertCallback(const v8::FunctionCallbackInfo<v8::Value>& info) {
175 try {

Callers 7

assertCallbackMethod · 0.85
errorCallbackMethod · 0.85
infoCallbackMethod · 0.85
logCallbackMethod · 0.85
warnCallbackMethod · 0.85
dirCallbackMethod · 0.85
traceCallbackMethod · 0.85

Calls 3

buildStringFromArgFunction · 0.85
GetIsolateMethod · 0.45
LengthMethod · 0.45

Tested by

no test coverage detected