示例#1
0
        /// <summary>
        /// Gets a named value from the specified scope.
        /// </summary>
        /// <param name="scope">The scope to get the property from.</param>
        /// <param name="propertyName">The name of the property to return.</param>
        public JsValue GetValue(JsValue scope, string propertyName)
        {
            AssertNotNullOrEmpty(nameof(propertyName), propertyName);

            var reference = _referencePool.Rent(scope, propertyName, _isStrict);
            var jsValue   = GetValue(reference, false);

            _referencePool.Return(reference);
            return(jsValue);
        }