예제 #1
0
        /// <summary>
        ///     Adds a reference to a script context.
        /// </summary>
        /// <remarks>
        ///     Calling AddRef ensures that the context will not be freed until Release is called.
        /// </remarks>
        /// <returns>The object's new reference count.</returns>
        public uint AddRef()
        {
            uint count;

            Native.ThrowIfError(Native.JsContextAddRef(this, out count));
            return(count);
        }
예제 #2
0
 /// <summary>
 ///     Adds a reference to a script context.
 /// </summary>
 /// <remarks>
 ///     Calling AddRef ensures that the context will not be freed until Release is called.
 /// </remarks>
 /// <returns>The object's new reference count.</returns>
 public UInt32 AddRef()
 {
     Native.ThrowIfError(Native.JsContextAddRef(this, out UInt32 count));
     return(count);
 }