()
| 139 | } |
| 140 | |
| 141 | writeEmbed() { |
| 142 | return new Proxy({}, { |
| 143 | get: (target, prop: string) => { |
| 144 | return (accessor: string) => { |
| 145 | const name = this.scope.declare( |
| 146 | "ext_ser", |
| 147 | TypeId.isNamedType(this.typeInfo.typeId) |
| 148 | ? this.builder.typeResolver.getSerializerByName(CodecBuilder.replaceBackslashAndQuote(this.typeInfo.named!)) |
| 149 | : this.builder.typeResolver.getSerializerById(this.typeInfo.typeId, this.typeInfo.userTypeId) |
| 150 | ); |
| 151 | return `${name}.${prop}(${accessor})`; |
| 152 | }; |
| 153 | }, |
| 154 | }); |
| 155 | } |
| 156 | |
| 157 | writeTypeInfo(): string { |
| 158 | const internalTypeId = this.getInternalTypeId(); |
nothing calls this directly
no test coverage detected