Is there any practial reason to create interface for abstract class? I encountered such thing:
public interface IEntity<T>
{
T Id { get; set; }
}
public abstract class BaseEntity {
}
public abstract class Entity<T> : BaseEntity, IEntity<T>
{
public virtual T Id { get; set; }
}
and i really don't understand what is the difference between that and this code, because IEntity is not a thing i whould use more than once:
public abstract class BaseEntity {
}
public abstract class Entity<T> : BaseEntity
{
public virtual T Id { get; set; }
}
Thanks!