/// <summary>Return the current WrapFactory, or null if none is defined.</summary> /// <remarks>Return the current WrapFactory, or null if none is defined.</remarks> /// <seealso cref="WrapFactory">WrapFactory</seealso> /// <since>1.5 Release 4</since> public WrapFactory GetWrapFactory() { if (wrapFactory == null) { wrapFactory = new WrapFactory(); } return wrapFactory; }
/// <summary>Set a WrapFactory for this Context.</summary> /// <remarks> /// Set a WrapFactory for this Context. /// <p> /// The WrapFactory allows custom object wrapping behavior for /// Java object manipulated with JavaScript. /// </remarks> /// <seealso cref="WrapFactory">WrapFactory</seealso> /// <since>1.5 Release 4</since> public void SetWrapFactory(WrapFactory wrapFactory) { if (@sealed) { OnSealedMutation(); } if (wrapFactory == null) { throw new ArgumentException(); } this.wrapFactory = wrapFactory; }