#include "third_party/blink/renderer/core/events/message_event.h"
#include <memory>
#include "third_party/blink/renderer/bindings/core/v8/to_v8_traits.h"
#include "third_party/blink/renderer/bindings/core/v8/v8_message_event_init.h"
#include "third_party/blink/renderer/core/event_interface_names.h"
#include "third_party/blink/renderer/core/frame/user_activation.h"
#include "third_party/blink/renderer/platform/bindings/exception_state.h"
#include "third_party/blink/renderer/platform/bindings/v8_binding.h"
namespace blink {
const V8PrivateProperty::SymbolKey kPrivatePropertyMessageEventCachedData;
static inline bool IsValidSource(EventTarget* source) { … }
size_t MessageEvent::SizeOfExternalMemoryInBytes() { … }
MessageEvent::MessageEvent() : … { … }
MessageEvent::MessageEvent(const AtomicString& type,
const MessageEventInit* initializer)
: … { … }
MessageEvent::MessageEvent(const String& origin,
const String& last_event_id,
EventTarget* source,
MessagePortArray* ports)
: … { … }
MessageEvent::MessageEvent(scoped_refptr<SerializedScriptValue> data,
const String& origin,
const String& last_event_id,
EventTarget* source,
MessagePortArray* ports,
UserActivation* user_activation)
: … { … }
MessageEvent::MessageEvent(
scoped_refptr<SerializedScriptValue> data,
const String& origin,
const String& last_event_id,
EventTarget* source,
Vector<MessagePortChannel> channels,
UserActivation* user_activation,
mojom::blink::DelegatedCapability delegated_capability)
: … { … }
MessageEvent::MessageEvent(const String& origin, EventTarget* source)
: … { … }
MessageEvent::MessageEvent(const String& data, const String& origin)
: … { … }
MessageEvent::MessageEvent(Blob* data, const String& origin)
: … { … }
MessageEvent::MessageEvent(DOMArrayBuffer* data, const String& origin)
: … { … }
MessageEvent* MessageEvent::Create(const AtomicString& type,
const MessageEventInit* initializer,
ExceptionState& exception_state) { … }
void MessageEvent::initMessageEvent(const AtomicString& type,
bool bubbles,
bool cancelable,
const ScriptValue& data,
const String& origin,
const String& last_event_id,
EventTarget* source,
MessagePortArray& ports) { … }
void MessageEvent::initMessageEvent(
const AtomicString& type,
bool bubbles,
bool cancelable,
scoped_refptr<SerializedScriptValue> data,
const String& origin,
const String& last_event_id,
EventTarget* source,
MessagePortArray* ports,
UserActivation* user_activation,
mojom::blink::DelegatedCapability delegated_capability) { … }
void MessageEvent::initMessageEvent(const AtomicString& type,
bool bubbles,
bool cancelable,
const String& data,
const String& origin,
const String& last_event_id,
EventTarget* source,
MessagePortArray* ports) { … }
ScriptValue MessageEvent::data(ScriptState* script_state) { … }
const AtomicString& MessageEvent::InterfaceName() const { … }
MessagePortArray MessageEvent::ports() { … }
bool MessageEvent::IsOriginCheckRequiredToAccessData() const { … }
bool MessageEvent::IsLockedToAgentCluster() const { … }
bool MessageEvent::CanDeserializeIn(ExecutionContext* execution_context) const { … }
void MessageEvent::EntangleMessagePorts(ExecutionContext* context) { … }
void MessageEvent::Trace(Visitor* visitor) const { … }
void MessageEvent::LockToAgentCluster() { … }
v8::Local<v8::Object> MessageEvent::AssociateWithWrapper(
v8::Isolate* isolate,
const WrapperTypeInfo* wrapper_type,
v8::Local<v8::Object> wrapper) { … }
}