ToStringJS() private method

private ToStringJS ( ScriptEngine engine, object thisObject ) : string
engine ScriptEngine
thisObject object
return string
Example #1
0
        /// <summary>
        /// Returns a string representing this object.
        /// </summary>
        /// <returns> A string representing this object. </returns>
        public override string ToString()
        {
            // Try calling WrappedInstance.join().
            object result;

            if (WrappedInstance.TryCallMemberFunction(out result, "join") == true)
            {
                return(TypeConverter.ToString(result));
            }

            // Otherwise, use the default Object.prototype.toString() method.
            return(ObjectInstance.ToStringJS(Engine, WrappedInstance));
        }