public bool Delete(string Feature, string CompatibleSchemaVersion) { bool toReturn = false; using(DataAccessAdapterBase adapter = (new DataAccessAdapterFactory()).CreateAdapter()) { AspnetSchemaVersionsEntity _AspnetSchemaVersionsEntity = new AspnetSchemaVersionsEntity(Feature, CompatibleSchemaVersion); if (adapter.FetchEntity(_AspnetSchemaVersionsEntity)) { adapter.DeleteEntity(_AspnetSchemaVersionsEntity); toReturn = true; } } return toReturn; }
public bool Update(string Feature, string CompatibleSchemaVersion, bool IsCurrentVersion) { bool toReturn = false; using(DataAccessAdapterBase adapter = (new DataAccessAdapterFactory()).CreateAdapter()) { AspnetSchemaVersionsEntity _AspnetSchemaVersionsEntity = new AspnetSchemaVersionsEntity(Feature, CompatibleSchemaVersion); if (adapter.FetchEntity(_AspnetSchemaVersionsEntity)) { _AspnetSchemaVersionsEntity.IsCurrentVersion = IsCurrentVersion; adapter.SaveEntity(_AspnetSchemaVersionsEntity, true); toReturn = true; } } return toReturn; }
public bool Update(AspnetSchemaVersionsEntity _AspnetSchemaVersionsEntity, RelationPredicateBucket filter) { bool toReturn = false; using(DataAccessAdapterBase adapter = (new DataAccessAdapterFactory()).CreateAdapter()) { adapter.UpdateEntitiesDirectly(_AspnetSchemaVersionsEntity, filter); toReturn = true; } return toReturn; }
public bool Update(AspnetSchemaVersionsEntity _AspnetSchemaVersionsEntity) { bool toReturn = false; using(DataAccessAdapterBase adapter = (new DataAccessAdapterFactory()).CreateAdapter()) { RelationPredicateBucket filter = new RelationPredicateBucket(); IPredicateExpression _PredicateExpression = new PredicateExpression(); _PredicateExpression.Add(AspnetSchemaVersionsFields.Feature == _AspnetSchemaVersionsEntity.Feature); _PredicateExpression.Add(AspnetSchemaVersionsFields.CompatibleSchemaVersion == _AspnetSchemaVersionsEntity.CompatibleSchemaVersion); filter.PredicateExpression.Add(_PredicateExpression); adapter.UpdateEntitiesDirectly(_AspnetSchemaVersionsEntity, filter); toReturn = true; } return toReturn; }
public AspnetSchemaVersionsEntity SelectOne(string Feature, string CompatibleSchemaVersion) { AspnetSchemaVersionsEntity toReturn = null; using(DataAccessAdapterBase adapter = (new DataAccessAdapterFactory()).CreateAdapter()) { AspnetSchemaVersionsEntity _AspnetSchemaVersionsEntity = new AspnetSchemaVersionsEntity(Feature, CompatibleSchemaVersion); if (adapter.FetchEntity(_AspnetSchemaVersionsEntity)) { toReturn = _AspnetSchemaVersionsEntity; } } return toReturn; }
public AspnetSchemaVersionsEntity Insert(bool IsCurrentVersion) { AspnetSchemaVersionsEntity _AspnetSchemaVersionsEntity = new AspnetSchemaVersionsEntity(); using(DataAccessAdapterBase adapter = (new DataAccessAdapterFactory()).CreateAdapter()) { _AspnetSchemaVersionsEntity.IsCurrentVersion = IsCurrentVersion; adapter.SaveEntity(_AspnetSchemaVersionsEntity, true); } return _AspnetSchemaVersionsEntity; }
public AspnetSchemaVersionsEntity Insert(string Feature, string CompatibleSchemaVersion, bool IsCurrentVersion) { AspnetSchemaVersionsEntity _AspnetSchemaVersionsEntity = new AspnetSchemaVersionsEntity(); using(DataAccessAdapterBase adapter = (new DataAccessAdapterFactory()).CreateAdapter()) { _AspnetSchemaVersionsEntity.Feature = Feature; _AspnetSchemaVersionsEntity.CompatibleSchemaVersion = CompatibleSchemaVersion; _AspnetSchemaVersionsEntity.IsCurrentVersion = IsCurrentVersion; adapter.SaveEntity(_AspnetSchemaVersionsEntity, true); } return _AspnetSchemaVersionsEntity; }
public AspnetSchemaVersionsEntity Insert(AspnetSchemaVersionsEntity _AspnetSchemaVersionsEntity) { using(DataAccessAdapterBase adapter = (new DataAccessAdapterFactory()).CreateAdapter()) { adapter.SaveEntity(_AspnetSchemaVersionsEntity, true); } return _AspnetSchemaVersionsEntity; }