using System; using System.Collections.Generic; using System.ComponentModel; using System.ComponentModel.DataAnnotations; using System.Linq; using System.Linq.Expressions; using System.Threading; using System.Threading.Tasks; using AutoMapper; using Util.Domains; using Util.Domains.Repositories; namespace Util.Tests.Samples { /// /// 实体样例 /// [DisplayName( "实体样例" )] public class EntitySample : AggregateRoot { public EntitySample( ) : this( Guid.NewGuid() ) { } public EntitySample( Guid id ) : base( id ) { } /// /// 名称 /// [Required(ErrorMessage = "名称不能为空")] public string Name { get; set; } /// /// 忽略值 /// [IgnoreMap] public string IgnoreValue { get; set; } } /// /// 仓储样例 /// public interface IRepositorySample : IRepository { } /// /// 仓储样例 /// public class RepositorySample : IRepositorySample { public IQueryable Find() { throw new NotImplementedException(); } public IQueryable FindAsNoTracking() { throw new NotImplementedException(); } public IQueryable Find( ICriteria criteria ) { throw new NotImplementedException(); } public IQueryable Find( Expression> predicate ) { throw new NotImplementedException(); } public EntitySample Find( object id ) { return new EntitySample(); } public Task FindAsync( object id ) { throw new NotImplementedException(); } public List FindByIds( params Guid[] ids ) { throw new NotImplementedException(); } public List FindByIds( IEnumerable ids ) { throw new NotImplementedException(); } public List FindByIds( string ids ) { throw new NotImplementedException(); } public Task> FindByIdsAsync( params Guid[] ids ) { throw new NotImplementedException(); } public Task> FindByIdsAsync( IEnumerable ids, CancellationToken cancellationToken = default( CancellationToken ) ) { throw new NotImplementedException(); } public Task> FindByIdsAsync( IEnumerable ids ) { throw new NotImplementedException(); } public Task> FindByIdsAsync( string ids ) { throw new NotImplementedException(); } public EntitySample Single( Expression> predicate ) { throw new NotImplementedException(); } public Task SingleAsync( Expression> predicate, CancellationToken cancellationToken = default( CancellationToken ) ) { throw new NotImplementedException(); } public List FindAll( Expression> predicate = null ) { throw new NotImplementedException(); } public Task> FindAllAsync( Expression> predicate = null ) { throw new NotImplementedException(); } public bool Exists( Expression> predicate ) { throw new NotImplementedException(); } public bool Exists( params Guid[] ids ) { throw new NotImplementedException(); } public Task ExistsAsync( Expression> predicate ) { throw new NotImplementedException(); } public Task ExistsAsync( params Guid[] ids ) { throw new NotImplementedException(); } public int Count( Expression> predicate = null ) { throw new NotImplementedException(); } public Task CountAsync( Expression> predicate = null ) { throw new NotImplementedException(); } public List Query( IQueryBase query ) { throw new NotImplementedException(); } public Task> QueryAsync( IQueryBase query ) { throw new NotImplementedException(); } public List QueryAsNoTracking( IQueryBase query ) { throw new NotImplementedException(); } public Task> QueryAsNoTrackingAsync( IQueryBase query ) { throw new NotImplementedException(); } public PagerList PagerQuery( IQueryBase query ) { throw new NotImplementedException(); } public Task> PagerQueryAsync( IQueryBase query ) { throw new NotImplementedException(); } public PagerList PagerQueryAsNoTracking( IQueryBase query ) { throw new NotImplementedException(); } public Task> PagerQueryAsNoTrackingAsync( IQueryBase query ) { throw new NotImplementedException(); } public IQueryable OrderBy( IQueryable queryable, string orderBy ) { throw new NotImplementedException(); } public void Add( EntitySample entity ) { } public void Add( IEnumerable entities ) { throw new NotImplementedException(); } public Task AddAsync( EntitySample entity, CancellationToken cancellationToken = default( CancellationToken ) ) { throw new NotImplementedException(); } public Task AddAsync( IEnumerable entities, CancellationToken cancellationToken = default( CancellationToken ) ) { throw new NotImplementedException(); } public Task AddAsync( EntitySample entity ) { throw new NotImplementedException(); } public Task AddAsync( IEnumerable entities ) { throw new NotImplementedException(); } public void Update( EntitySample entity ) { } public void Update( IEnumerable entities ) { throw new NotImplementedException(); } public Task UpdateAsync( EntitySample entity ) { throw new NotImplementedException(); } public Task UpdateAsync( IEnumerable entities ) { throw new NotImplementedException(); } public void Remove( Guid id ) { throw new NotImplementedException(); } public Task RemoveAsync( Guid id, CancellationToken cancellationToken = default( CancellationToken ) ) { throw new NotImplementedException(); } public Task RemoveAsync( Guid id ) { throw new NotImplementedException(); } public void Remove( object id ) { throw new NotImplementedException(); } public void Remove( EntitySample entity ) { throw new NotImplementedException(); } public Task RemoveAsync( object id, CancellationToken cancellationToken = default( CancellationToken ) ) { throw new NotImplementedException(); } public Task RemoveAsync( EntitySample entity, CancellationToken cancellationToken = default( CancellationToken ) ) { throw new NotImplementedException(); } public Task RemoveAsync( EntitySample entity ) { throw new NotImplementedException(); } public void Remove( IEnumerable ids ) { throw new NotImplementedException(); } public Task RemoveAsync( IEnumerable ids, CancellationToken cancellationToken = default( CancellationToken ) ) { throw new NotImplementedException(); } public Task RemoveAsync( IEnumerable ids ) { throw new NotImplementedException(); } public void Remove( IEnumerable entities ) { throw new NotImplementedException(); } public Task RemoveAsync( IEnumerable entities, CancellationToken cancellationToken = default( CancellationToken ) ) { throw new NotImplementedException(); } public Task RemoveAsync( IEnumerable entities ) { throw new NotImplementedException(); } public Task FindAsync( object id, CancellationToken cancellationToken = default( CancellationToken ) ) { throw new NotImplementedException(); } public EntitySample FindByIdNoTracking( Guid id ) { throw new NotImplementedException(); } public Task FindByIdNoTrackingAsync( Guid id, CancellationToken cancellationToken = default( CancellationToken ) ) { throw new NotImplementedException(); } public List FindByIdsNoTracking( params Guid[] ids ) { throw new NotImplementedException(); } public List FindByIdsNoTracking( IEnumerable ids ) { throw new NotImplementedException(); } public List FindByIdsNoTracking( string ids ) { throw new NotImplementedException(); } public Task> FindByIdsNoTrackingAsync( params Guid[] ids ) { throw new NotImplementedException(); } public Task> FindByIdsNoTrackingAsync( IEnumerable ids, CancellationToken cancellationToken = default( CancellationToken ) ) { throw new NotImplementedException(); } public Task> FindByIdsNoTrackingAsync( string ids ) { throw new NotImplementedException(); } public List FindAllNoTracking( Expression> predicate = null ) { throw new NotImplementedException(); } public Task> FindAllNoTrackingAsync( Expression> predicate = null ) { throw new NotImplementedException(); } } }