Hi Again

I've exposed my objects (whose properties are dynamic) to JavaScript
by deriving from ScriptableObject and generally all is good.

But I've failed to properly deal with this JavaScript scenario:
    try {
         myObject.notMyProperty = "hello"
    }
    catch(e) {
          "unrecognized property"
    }
    "hello world"

My question is: in myObject's put(String, Scriptable, Object) method,
what kind of RhinoException do I throw when myObject recognizes that
notMyProperty is invalid, so that catch block in the above script gets
executed as well as any code that follows.

I wish the docs for Scriptable and/or ScriptableObject would expand  a
bit more on exception handling.
_______________________________________________
dev-tech-js-engine-rhino mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-tech-js-engine-rhino

Reply via email to