本文整理汇总了C++中TrackExceptionState::code方法的典型用法代码示例。如果您正苦于以下问题:C++ TrackExceptionState::code方法的具体用法?C++ TrackExceptionState::code怎么用?C++ TrackExceptionState::code使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TrackExceptionState
的用法示例。
在下文中一共展示了TrackExceptionState::code方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: querySelector
WebElement WebNode::querySelector(const WebString& tag, WebExceptionCode& ec) const
{
TrackExceptionState es;
WebElement element(m_private->querySelector(tag, es));
ec = es.code();
return element;
}
开发者ID:IllusionRom-deprecated,项目名称:android_platform_external_chromium_org_third_party_WebKit,代码行数:7,代码来源:WebNode.cpp
示例2: querySelector
WebElement WebNode::querySelector(const WebString& tag, WebExceptionCode& ec) const
{
TrackExceptionState exceptionState;
WebElement element;
if (m_private->isContainerNode())
element = toContainerNode(m_private.get())->querySelector(tag, exceptionState);
ec = exceptionState.code();
return element;
}
示例3: dictionary
v8::Handle<v8::Value> WebDocument::registerEmbedderCustomElement(const WebString& name, v8::Handle<v8::Value> options, WebExceptionCode& ec)
{
v8::Isolate* isolate = v8::Isolate::GetCurrent();
Document* document = unwrap<Document>();
Dictionary dictionary(options, isolate);
TrackExceptionState exceptionState;
ScriptValue constructor = document->registerElement(ScriptState::current(isolate), name, dictionary, exceptionState, CustomElement::EmbedderNames);
ec = exceptionState.code();
if (exceptionState.hadException())
return v8::Handle<v8::Value>();
return constructor.v8Value();
}
示例4: populateForm
TEST_F(PasswordCredentialTest, CreateFromFormNoId)
{
HTMLFormElement* form = populateForm("multipart/form-data",
"<!-- No username field. -->"
"<input type='text' name='thePassword' value='sekrit' autocomplete='current-password'>"
"<input type='text' name='theIcon' value='https://example.com/photo' autocomplete='photo'>"
"<input type='text' name='theName' value='friendly name' autocomplete='name'>");
TrackExceptionState exceptionState;
PasswordCredential* credential = PasswordCredential::create(form, exceptionState);
EXPECT_EQ(nullptr, credential);
EXPECT_TRUE(exceptionState.hadException());
EXPECT_EQ(V8TypeError, exceptionState.code());
EXPECT_EQ("'id' must not be empty.", exceptionState.message());
}
示例5:
v8::Local<v8::Value> WebDocument::registerEmbedderCustomElement(const WebString& name, v8::Local<v8::Value> options, WebExceptionCode& ec)
{
v8::Isolate* isolate = v8::Isolate::GetCurrent();
Document* document = unwrap<Document>();
TrackExceptionState exceptionState;
ElementRegistrationOptions registrationOptions;
V8ElementRegistrationOptions::toImpl(isolate, options, registrationOptions, exceptionState);
if (exceptionState.hadException())
return v8::Local<v8::Value>();
ScriptValue constructor = document->registerElement(ScriptState::current(isolate), name, registrationOptions, exceptionState, CustomElement::EmbedderNames);
ec = exceptionState.code();
if (exceptionState.hadException())
return v8::Local<v8::Value>();
return constructor.v8Value();
}