Hi,

I want to embed v8 into my vxml interpreter. In vxml interpreter there
is a scopes like session, application, document, anonimous etc. I want
to maintain these scope using v8 apis. Actually I want to maintain
these scopes usings v8 APIs. When I in session scope then if I
evaluate any script in session scope then every javascript variable
declared as "var a = 10;" then I can get the value of variable using
"session.a" by compling and running this script using v8 api:
        Handle<Script> script = Script::Compile(String::New
("session.a"));
        if(script.IsEmpty())
        {
                //Throw error
        }
        else
        {
                Handle<Value> result = script->Run();
                if(result.IsEmpty())
                {
                        //throw error;
                }
               else
               {
                        fprintf(stderr, "value of a = %d\n", result-
>Int32Value()); // value of a should be printed 10
               }
         }

When I pop the scope then variable "a" should not be accessed becouse
"a" axist in session scope and session scope has been poped off.

Please any body help me for doing this thing using v8 APIs. If
possible, please provide sample code


Thanks in advance
--~--~---------~--~----~------------~-------~--~----~
v8-users mailing list
[email protected]
http://groups.google.com/group/v8-users
-~----------~----~----~----~------~----~------~--~---

Reply via email to