mirror of
https://github.com/theoludwig/p61-project.git
synced 2024-07-17 07:00:12 +02:00
17 lines
322 B
TypeScript
17 lines
322 B
TypeScript
export interface EntityOptions {
|
|
id: string
|
|
}
|
|
|
|
export abstract class Entity implements EntityOptions {
|
|
public readonly id: string
|
|
|
|
public constructor(options: EntityOptions) {
|
|
const { id } = options
|
|
this.id = id
|
|
}
|
|
|
|
// public equals(entity: Entity): boolean {
|
|
// return entity.id === this.id
|
|
// }
|
|
}
|