#include "src/inspector/string-util.h"
#include <cinttypes>
#include <cmath>
#include <cstddef>
#include "src/base/platform/platform.h"
#include "src/inspector/protocol/Protocol.h"
#include "src/numbers/conversions.h"
namespace v8_inspector {
namespace protocol {
namespace {
std::pair<uint8_t, uint8_t> SplitByte(uint8_t byte, uint8_t split) { … }
v8::Maybe<uint8_t> DecodeByte(char byte) { … }
}
String Binary::toBase64() const { … }
Binary Binary::fromBase64(const String& base64, bool* success) { … }
}
v8::Local<v8::String> toV8String(v8::Isolate* isolate, const String16& string) { … }
v8::Local<v8::String> toV8StringInternalized(v8::Isolate* isolate,
const String16& string) { … }
v8::Local<v8::String> toV8StringInternalized(v8::Isolate* isolate,
const char* str) { … }
v8::Local<v8::String> toV8String(v8::Isolate* isolate,
const StringView& string) { … }
String16 toProtocolString(v8::Isolate* isolate, v8::Local<v8::String> value) { … }
String16 toProtocolStringWithTypeCheck(v8::Isolate* isolate,
v8::Local<v8::Value> value) { … }
String16 toString16(const StringView& string) { … }
StringView toStringView(const String16& string) { … }
bool stringViewStartsWith(const StringView& string, const char* prefix) { … }
namespace {
class EmptyStringBuffer : public StringBuffer { … };
class StringBuffer8 : public StringBuffer { … };
class StringBuffer16 : public StringBuffer { … };
}
std::unique_ptr<StringBuffer> StringBuffer::create(StringView string) { … }
std::unique_ptr<StringBuffer> StringBufferFrom(String16 str) { … }
std::unique_ptr<StringBuffer> StringBufferFrom(std::vector<uint8_t> str) { … }
String16 stackTraceIdToString(uintptr_t id) { … }
}
namespace v8_crdtp {
String16;
Binary;
StringUtil;
bool ProtocolTypeTraits<String16>::Deserialize(DeserializerState* state,
String16* value) { … }
void ProtocolTypeTraits<String16>::Serialize(const String16& value,
std::vector<uint8_t>* bytes) { … }
bool ProtocolTypeTraits<Binary>::Deserialize(DeserializerState* state,
Binary* value) { … }
void ProtocolTypeTraits<Binary>::Serialize(const Binary& value,
std::vector<uint8_t>* bytes) { … }
}