예제 #1
0
파일: Engine.cs 프로젝트: rockyjvec/SpaceJS
        /// <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);
        }