WebKit之V8编写简单demon
来源:互联网 发布:淘宝中的延长收货 编辑:程序博客网 时间:2024/04/19 12:33
## 测试 testv8.cxx
- // testv8.cpp : Defines the entry point for the console application.
- //
- #include <v8.h>
- using namespace v8;
- int main(int argc, char* argv[]) {
- // Create a stack-allocated handle scope.
- HandleScope handle_scope;
- // Create a new context.
- Persistent<Context> context = Context::New();
- // Enter the created context for compiling and
- // running the hello world script.
- Context::Scope context_scope(context);
- // Create a string containing the JavaScript source code.
- Handle<String> source = String::New("var x='xyziamheres2///sdfsdf123'; x.match(/\\d{3,3}/);");
- // Compile the source code.
- Handle<Script> script = Script::Compile(source);
- // Run the script to get the result.
- Handle<Value> result = script->Run();
- // Dispose the persistent context.
- context.Dispose();
- // Convert the result to an ASCII string and print it.
- String::AsciiValue ascii(result);
- printf("%s\n", *ascii);
- return 0;
- }
0 0
- WebKit之V8编写简单demon
- 浅谈WebKit之JavaScriptCore/V8
- WebKit之JavaScriptCore/V8篇
- 浅谈WebKit之JavaScriptCore/V8篇
- 浅谈WebKit之 JavaScriptCore/V8篇
- 浅谈WebKit之JavaScriptCore/V8篇
- WebKit之V8的详细介绍
- WebKit之V8引擎(js调度C++)
- WebKit之V8技术优化分析
- webkit v8扩展
- WebKit之XMLHttpRequest简单分析
- Qt开发之webkit(编写网页浏览器)
- webkit和v8的关系
- webkit与V8前话
- 沙盒开机动画简单demon
- WebKit之如何实现JS DOM binding—基于V8分析
- WebKit之MediaPlayer的简单分析
- Webkit之webkit
- iPhone屏幕像素 分辨率 xcode中的逻辑宽高的介绍以及strcut与class的区别
- HDU 4560解题报告
- 华为机试题:整数排序
- HDU3371 并查集与最小生成树(判断有无生成树)
- segfault at xxx rip xxx rsp xxx error 4
- WebKit之V8编写简单demon
- C语言 求一个数列的前n项之和,保留两位小数。
- win7下安装/卸载VirtualBox时出错
- MFC下ADO访问ACCESS插入日期
- cocos2d-x核心概念(四)——动作,动画
- mac升级到10.11.3后CocoaPods不可用的解决办法
- Check the existence of public synonyms Remove the public synonyms
- centos6 postfix配置
- P站来的福利(第三波)