예제 #1
0
파일: ILScanner.cs 프로젝트: kztao/FlingOS
        /// <summary>
        /// Processes the static fields on the specified type.
        /// </summary>
        /// <param name="theType">The type to process.</param>
        private void ProcessStaticFields(Type theType)
        {
            FieldInfo[] staticFields = theType.GetFields(BindingFlags.Static | BindingFlags.NonPublic | BindingFlags.Public);
            foreach(FieldInfo anInfo in staticFields)
            {
                string FieldID = TheScannerState.AddStaticField(anInfo);

                DB_StaticField dbStaticField = new DB_StaticField();
                dbStaticField.Id = FieldID;
                dbStaticField.TypeID = ProcessType(anInfo.FieldType).Id;
                dbStaticField.DeclaringTypeID = ProcessType(anInfo.DeclaringType).Id;
                DebugDatabase.AddStaticField(dbStaticField);
            }
        }
예제 #2
0
 partial void UpdateDB_StaticField(DB_StaticField instance);
예제 #3
0
 partial void DeleteDB_StaticField(DB_StaticField instance);
예제 #4
0
 partial void InsertDB_StaticField(DB_StaticField instance);
예제 #5
0
		private void detach_StaticFields1(DB_StaticField entity)
		{
			this.SendPropertyChanging();
			entity.DB_Type1 = null;
		}
예제 #6
0
		private void attach_StaticFields(DB_StaticField entity)
		{
			this.SendPropertyChanging();
			entity.DB_Type = this;
		}
예제 #7
0
 /// <summary>
 /// Removes the specified static field from the database.
 /// <para>To Do's: See <see cref="RemoveMethod"/>'s to do's.</para>
 /// </summary>
 /// <param name="aStaticField">The entry to remove.</param>
 /// <remarks>
 /// <para>
 /// For the moment this method does no more than just directly remove
 /// the entry from the database.
 /// </para>
 /// <para>
 /// <see cref="SubmitChanges"/> must be called at some point after this
 /// method for changes to actually be submitted to the database.
 /// </para>
 /// </remarks>
 public static void RemoveStaticField(DB_StaticField aStaticField)
 {
     DB.DB_StaticFields.DeleteOnSubmit(aStaticField);
 }
예제 #8
0
 /// <summary>
 /// Adds the pre-created static field to the database. All the entries's
 /// required parameters (i.e. ones which cannot be null) should 
 /// be set.
 /// <para>To Do's: See <see cref="AddMethod"/>'s to do's.</para>
 /// </summary>
 /// <param name="aStaticField">The entry to add.</param>
 /// <remarks>
 /// <para>
 /// For the moment this method does no more than just directly add
 /// the entry to the database.
 /// </para>
 /// <para>
 /// <see cref="SubmitChanges"/> must be called at some point after this
 /// method for changes to actually be submitted to the database.
 /// </para>
 /// </remarks>
 public static void AddStaticField(DB_StaticField aStaticField)
 {
     DB.DB_StaticFields.InsertOnSubmit(aStaticField);
 }