internal JSPredefinedField(string name, MemberTypes memberType, GlobalObjectInstance globalObject) : base(name, 0, null) { m_memberType = memberType; m_globalObject = globalObject; // predefined fields cannot be crunched CanCrunch = false; }
public GlobalObject(GlobalObjectInstance globalObject, string[] properties, string[] methods) { m_fieldMap = new Dictionary <string, JSPredefinedField>(); // itemize all the properties if (properties != null) { foreach (string fieldName in properties) { m_fieldMap.Add(fieldName, new JSPredefinedField(fieldName, MemberTypes.Property, globalObject)); } } // itemize all the methods if (methods != null) { foreach (string fieldName in methods) { m_fieldMap.Add(fieldName, new JSPredefinedField(fieldName, MemberTypes.Method, globalObject)); } } }
public GlobalObject(GlobalObjectInstance globalObject, string[] properties, string[] methods) { m_fieldMap = new Dictionary<string,JSPredefinedField>(); // itemize all the properties if (properties != null) { foreach(string fieldName in properties) { m_fieldMap.Add(fieldName, new JSPredefinedField(fieldName, MemberTypes.Property, globalObject)); } } // itemize all the methods if (methods != null) { foreach(string fieldName in methods) { m_fieldMap.Add(fieldName, new JSPredefinedField(fieldName, MemberTypes.Method, globalObject)); } } }