public DebugDocument(WindowsScriptEngine engine, UIntPtr sourceContext, DocumentInfo documentInfo, string code)
 {
     this.engine        = engine;
     this.sourceContext = sourceContext;
     this.documentInfo  = documentInfo;
     this.code          = code;
     Initialize();
 }
Ejemplo n.º 2
0
 public DebugDocument(WindowsScriptEngine engine, UIntPtr sourceContext, string name, string code, bool transient)
 {
     this.engine        = engine;
     this.sourceContext = sourceContext;
     this.name          = name + (transient ? " [temp]" : "");
     this.code          = code;
     Initialize();
 }
Ejemplo n.º 3
0
        public static object Wrap(WindowsScriptEngine engine, object obj)
        {
            Debug.Assert(!(obj is IScriptMarshalWrapper));

            if (obj == null)
            {
                return(null);
            }

            if ((obj is IDispatchEx target) && (obj.GetType().IsCOMObject))
            {
                return(new WindowsScriptItem(engine, target));
            }

            return(obj);
        }
Ejemplo n.º 4
0
        public static object Wrap(WindowsScriptEngine engine, object obj)
        {
            Debug.Assert(!(obj is IScriptMarshalWrapper));

            if (obj == null)
            {
                return(null);
            }

            var expando = obj as IExpando;

            if ((expando != null) && (obj.GetType().IsCOMObject))
            {
                return(new WindowsScriptItem(engine, expando));
            }

            return(obj);
        }
 public ScriptSite(WindowsScriptEngine engine)
 {
     this.engine = engine;
 }
Ejemplo n.º 6
0
 private WindowsScriptItem(WindowsScriptEngine engine, IExpando target)
 {
     this.engine = engine;
     this.target = target;
 }
Ejemplo n.º 7
0
 private WindowsScriptItem(WindowsScriptEngine engine, IDispatchEx target)
 {
     this.engine = engine;
     this.target = target;
 }