예제 #1
0
 public @ref(CodeContext context, object target, object callback = null)
 {
     WeakRefHelpers.InitializeWeakRef(context.LanguageContext, this, target, callback);
     _target      = new WeakHandle(target, false);
     _context     = context;
     __callback__ = callback;
 }
예제 #2
0
            public void __init__(CodeContext context, object ob, object callback = null)
            {
                _context = context;
                WeakRefTracker wrt = WeakRefHelpers.InitializeWeakRef(_context.LanguageContext, this, ob, callback);

                _target   = new WeakHandle(ob, false);
                _targetId = wrt.TargetId;
            }
예제 #3
0
            public @ref(CodeContext context, object @object, object callback)
            {
                _context = context;
                WeakRefTracker wrt = WeakRefHelpers.InitializeWeakRef(_context.GetPythonContext(), this, @object, callback);

                _target   = new WeakHandle(@object, false);
                _targetId = wrt.TargetId;
            }
예제 #4
0
 private weakcallableproxy(CodeContext context, object target, object callback)
 {
     WeakRefHelpers.InitializeWeakRef(context.LanguageContext, this, target, callback);
     _target  = new WeakHandle(target, false);
     _context = context;
 }
예제 #5
0
 private weakproxy(CodeContext /*!*/ context, object target, object callback)
 {
     WeakRefHelpers.InitializeWeakRef(PythonContext.GetContext(context), this, target, callback);
     _target  = new WeakHandle(target, false);
     _context = context;
 }
예제 #6
0
 public @ref(CodeContext context, object @object, object callback)
 {
     this._context = context;
     WeakRefHelpers.InitializeWeakRef(this._context.GetPythonContext(), this, @object, callback);
     this._target = new WeakHandle(@object, false);
 }
예제 #7
0
 public @ref(object @object, object callback)
 {
     WeakRefHelpers.InitializeWeakRef(this, @object, callback);
     this._target = new WeakHandle(@object, false);
 }
예제 #8
0
 private PythonCallableWeakRefProxy(object target, object callback)
 {
     WeakRefHelpers.InitializeWeakRef(this, target, callback);
     this.target = GCHandle.Alloc(target, GCHandleType.Weak);
 }
예제 #9
0
 public PythonWeakReference(object @object, object callback)
 {
     WeakRefHelpers.InitializeWeakRef(this, @object, callback);
     this.target = GCHandle.Alloc(@object, GCHandleType.Weak);
 }