Skip to content

Latest commit

 

History

History
70 lines (37 loc) · 1.19 KB

Entity.md

File metadata and controls

70 lines (37 loc) · 1.19 KB

redis-om / Entity

Class: Entity

An Entity is the class from which objects that Redis OM maps to are made. You need to subclass Entity in your application:

class Foo extends Entity {}

Table of contents

Properties

Accessors

Methods

Properties

entityId

Readonly entityId: string

The generated entity ID.

Defined in

lib/entity/entity.ts:37

Accessors

keyName

get keyName(): string

Returns

string

The keyname this Entity is stored with in Redis.

Defined in

lib/entity/entity.ts:73

Methods

toJSON

toJSON(): Record<string, any>

Converts this Entity to a JavaScript object suitable for stringification.

Returns

Record<string, any>

a JavaScript object.

Defined in

lib/entity/entity.ts:81