예제 #1
0
파일: Enum.cs 프로젝트: fjgandrade/sharpkit
        /// <summary>
        /// Retrieves an array of the values of the constants in a specified enumeration.
        /// </summary>
        /// <param name="enumType">Type of the enum.</param>
        /// <returns>An array that contains the values of the constants in enumType.</returns>
        /// <exception cref="ArgumentNullException"><para>enumType</para> is null.</exception>
        public static object[] GetValues(Type enumType)
		{
            if (enumType == null) throw new ArgumentNullException("enumType");

            var jsType = enumType.As<JsImplType>()._JsType;
			var array = new JsExtendedArray();
			foreach (var p in jsType.staticDefinition)
				array.push(jsType.staticDefinition[p]);
			return array.As<object[]>();
		}
예제 #2
0
파일: Enum.cs 프로젝트: fjgandrade/sharpkit
		public static object[] GetValues(Type type)
		{
			var jsType = type.As<JsImplType>()._JsType;
			var array = new JsExtendedArray();
			foreach (var p in jsType.staticDefinition)
			{
				array.push(jsType.staticDefinition[p]);
			}
			return array.As<object[]>();
		}
예제 #3
0
파일: Enum.cs 프로젝트: fjgandrade/sharpkit
		public static string[] GetNames(Type type)
		{
			var jsType = type.As<JsImplType>()._JsType;
			var array = new JsExtendedArray();
			foreach (var p in jsType.staticDefinition)
			{
				array.push(p);
			}
			return array.As<string[]>();
		}
예제 #4
0
        public static object[] GetValues(Type type)
        {
            var jsType = type.As <JsImplType>()._JsType;
            var array  = new JsExtendedArray();

            foreach (var p in jsType.staticDefinition)
            {
                array.push(jsType.staticDefinition[p]);
            }
            return(array.As <object[]>());
        }
예제 #5
0
        public static string[] GetNames(Type type)
        {
            var jsType = type.As <JsImplType>()._JsType;
            var array  = new JsExtendedArray();

            foreach (var p in jsType.staticDefinition)
            {
                array.push(p);
            }
            return(array.As <string[]>());
        }
예제 #6
0
        /// <summary>
        /// Retrieves an array of the values of the constants in a specified enumeration.
        /// </summary>
        /// <param name="enumType">Type of the enum.</param>
        /// <returns>An array that contains the values of the constants in enumType.</returns>
        /// <exception cref="ArgumentNullException"><para>enumType</para> is null.</exception>
        public static object[] GetValues(Type enumType)
        {
            if (enumType == null)
            {
                throw new ArgumentNullException("enumType");
            }

            var jsType = enumType.As <JsImplType>()._JsType;
            var array  = new JsExtendedArray();

            foreach (var p in jsType.staticDefinition)
            {
                array.push(jsType.staticDefinition[p]);
            }
            return(array.As <object[]>());
        }
예제 #7
0
 public JsImplPropertyInfo[] GetProperties()
 {
     VerifyProperties();
     return(_Properties.As <JsImplPropertyInfo[]>());
 }
예제 #8
0
 public void Sort()
 {
     //_list.sort();
     Array.Sort(_list.As <T[]>());
 }