Serializes the entity with control over which relations and fields to include or exclude.
(
options?: SerializeOptions<Naked, Hint, Exclude, Fields>,
)
| 124 | |
| 125 | /** Serializes the entity with control over which relations and fields to include or exclude. */ |
| 126 | serialize< |
| 127 | Entity extends this = this, |
| 128 | Naked extends FromEntityType<Entity> = FromEntityType<Entity>, |
| 129 | Hint extends string = never, |
| 130 | Exclude extends string = never, |
| 131 | Fields extends string = never, |
| 132 | >( |
| 133 | options?: SerializeOptions<Naked, Hint, Exclude, Fields>, |
| 134 | ): SerializeDTO< |
| 135 | Naked, |
| 136 | Hint, |
| 137 | Exclude, |
| 138 | never, |
| 139 | ResolveSerializeFields<Fields, ExtractFieldsHint<Entity>>, |
| 140 | SerializeFieldsKeepPK<Fields> |
| 141 | > { |
| 142 | return EntitySerializer.serialize(this as unknown as Naked, options) as any; |
| 143 | } |
| 144 | |
| 145 | /** Assigns the given data to this entity, updating its properties and relations. */ |
| 146 | assign< |
no test coverage detected