public void InsertSqlResourceType(SqlResourceType sqlResourceType)
 {
     if ((sqlResourceType.EntityState != EntityState.Detached))
     {
         this.ObjectContext.ObjectStateManager.ChangeObjectState(sqlResourceType, EntityState.Added);
     }
     else
     {
         this.ObjectContext.SqlResourceTypes.AddObject(sqlResourceType);
     }
 }
 public void DeleteSqlResourceType(SqlResourceType sqlResourceType)
 {
     if ((sqlResourceType.EntityState != EntityState.Detached))
     {
         this.ObjectContext.ObjectStateManager.ChangeObjectState(sqlResourceType, EntityState.Deleted);
     }
     else
     {
         this.ObjectContext.SqlResourceTypes.Attach(sqlResourceType);
         this.ObjectContext.SqlResourceTypes.DeleteObject(sqlResourceType);
     }
 }
 /// <summary>
 /// Deprecated Method for adding a new object to the SqlResourceTypes EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToSqlResourceTypes(SqlResourceType sqlResourceType)
 {
     base.AddObject("SqlResourceTypes", sqlResourceType);
 }
 /// <summary>
 /// Create a new SqlResourceType object.
 /// </summary>
 /// <param name="sqlResourceTypeId">Initial value of the SqlResourceTypeId property.</param>
 /// <param name="name">Initial value of the Name property.</param>
 /// <param name="allowMultipleSelection">Initial value of the AllowMultipleSelection property.</param>
 public static SqlResourceType CreateSqlResourceType(global::System.Int32 sqlResourceTypeId, global::System.String name, global::System.Boolean allowMultipleSelection)
 {
     SqlResourceType sqlResourceType = new SqlResourceType();
     sqlResourceType.SqlResourceTypeId = sqlResourceTypeId;
     sqlResourceType.Name = name;
     sqlResourceType.AllowMultipleSelection = allowMultipleSelection;
     return sqlResourceType;
 }
 private bool FilterSqlResourceType(SqlResourceType entity)
 {
     return (entity.SqlResourceTypeId == this.SqlResourceTypeId);
 }
 public void UpdateSqlResourceType(SqlResourceType currentSqlResourceType)
 {
     this.ObjectContext.SqlResourceTypes.AttachAsModified(currentSqlResourceType);
 }