C# 클래스 Jurassic.Library.PropertyDescriptor

Represents either a named data property, or a named accessor property.
파일 보기 프로젝트 열기: paulbartrum/jurassic 1 사용 예제들

공개 메소드들

메소드 설명
FromObject ( ObjectInstance obj, PropertyDescriptor defaults ) : PropertyDescriptor

Creates a property descriptor from an object containing any of the following properties: configurable, writable, enumerable, value, get, set.

PropertyDescriptor ( FunctionInstance getter, FunctionInstance setter, PropertyAttributes attributes ) : System

Creates a new PropertyDescriptor instance with a getter function and, optionally, a setter function.

PropertyDescriptor ( object value, PropertyAttributes attributes ) : System

Creates a new PropertyDescriptor instance.

ToObject ( ScriptEngine engine ) : ObjectInstance

Populates an object with the following properties: configurable, writable, enumerable, value, get, set.

ToString ( ) : string

Gets the property value, calling the get accessor, if present.

Returns a string representing the current object.

메소드 상세

FromObject() 공개 정적인 메소드

Creates a property descriptor from an object containing any of the following properties: configurable, writable, enumerable, value, get, set.
public static FromObject ( ObjectInstance obj, PropertyDescriptor defaults ) : PropertyDescriptor
obj ObjectInstance The object to get the property values from.
defaults PropertyDescriptor The values to use if the relevant value is not specified.
리턴 PropertyDescriptor

PropertyDescriptor() 공개 메소드

Creates a new PropertyDescriptor instance with a getter function and, optionally, a setter function.
public PropertyDescriptor ( FunctionInstance getter, FunctionInstance setter, PropertyAttributes attributes ) : System
getter FunctionInstance The function to call to retrieve the property value.
setter FunctionInstance The function to call to set the property value.
attributes PropertyAttributes The property attributes (whether the property is writable or /// not is implied by whether there is a setter function).
리턴 System

PropertyDescriptor() 공개 메소드

Creates a new PropertyDescriptor instance.
public PropertyDescriptor ( object value, PropertyAttributes attributes ) : System
value object The initial value for the property.
attributes PropertyAttributes The property attributes.
리턴 System

ToObject() 공개 메소드

Populates an object with the following properties: configurable, writable, enumerable, value, get, set.
public ToObject ( ScriptEngine engine ) : ObjectInstance
engine ScriptEngine The script engine used to create a new object.
리턴 ObjectInstance

ToString() 공개 메소드

Gets the property value, calling the get accessor, if present. Returns a string representing the current object.
public ToString ( ) : string
리턴 string