-
Notifications
You must be signed in to change notification settings - Fork 4.2k
/
coderx.shims.go
347 lines (275 loc) · 10 KB
/
coderx.shims.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
// Licensed to the Apache Software Foundation (ASF) under one or more
// contributor license agreements. See the NOTICE file distributed with
// this work for additional information regarding copyright ownership.
// The ASF licenses this file to You under the Apache License, Version 2.0
// (the "License"); you may not use this file except in compliance with
// the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
// Code generated by starcgen. DO NOT EDIT.
// File: coderx.shims.go
package coderx
import (
"reflect"
// Library imports
"github.com/apache/beam/sdks/go/pkg/beam/core/runtime"
"github.com/apache/beam/sdks/go/pkg/beam/core/typex"
"github.com/apache/beam/sdks/go/pkg/beam/core/util/reflectx"
)
func init() {
runtime.RegisterFunction(decFloat)
runtime.RegisterFunction(decInt32)
runtime.RegisterFunction(decInt64)
runtime.RegisterFunction(decString)
runtime.RegisterFunction(decUint32)
runtime.RegisterFunction(decUint64)
runtime.RegisterFunction(decVarIntZ)
runtime.RegisterFunction(decVarUintZ)
runtime.RegisterFunction(encFloat)
runtime.RegisterFunction(encInt32)
runtime.RegisterFunction(encInt64)
runtime.RegisterFunction(encString)
runtime.RegisterFunction(encUint32)
runtime.RegisterFunction(encUint64)
runtime.RegisterFunction(encVarIntZ)
runtime.RegisterFunction(encVarUintZ)
runtime.RegisterType(reflect.TypeOf((*reflect.Type)(nil)).Elem())
reflectx.RegisterFunc(reflect.TypeOf((*func(int32) []byte)(nil)).Elem(), funcMakerInt32ГSliceOfByte)
reflectx.RegisterFunc(reflect.TypeOf((*func(int64) []byte)(nil)).Elem(), funcMakerInt64ГSliceOfByte)
reflectx.RegisterFunc(reflect.TypeOf((*func(reflect.Type, []byte) (typex.T, error))(nil)).Elem(), funcMakerReflect۰TypeSliceOfByteГTypex۰TError)
reflectx.RegisterFunc(reflect.TypeOf((*func([]byte) int32)(nil)).Elem(), funcMakerSliceOfByteГInt32)
reflectx.RegisterFunc(reflect.TypeOf((*func([]byte) int64)(nil)).Elem(), funcMakerSliceOfByteГInt64)
reflectx.RegisterFunc(reflect.TypeOf((*func([]byte) typex.T)(nil)).Elem(), funcMakerSliceOfByteГTypex۰T)
reflectx.RegisterFunc(reflect.TypeOf((*func([]byte) uint32)(nil)).Elem(), funcMakerSliceOfByteГUint32)
reflectx.RegisterFunc(reflect.TypeOf((*func([]byte) uint64)(nil)).Elem(), funcMakerSliceOfByteГUint64)
reflectx.RegisterFunc(reflect.TypeOf((*func(typex.T) []byte)(nil)).Elem(), funcMakerTypex۰TГSliceOfByte)
reflectx.RegisterFunc(reflect.TypeOf((*func(uint32) []byte)(nil)).Elem(), funcMakerUint32ГSliceOfByte)
reflectx.RegisterFunc(reflect.TypeOf((*func(uint64) []byte)(nil)).Elem(), funcMakerUint64ГSliceOfByte)
}
type callerInt32ГSliceOfByte struct {
fn func(int32) []byte
}
func funcMakerInt32ГSliceOfByte(fn interface{}) reflectx.Func {
f := fn.(func(int32) []byte)
return &callerInt32ГSliceOfByte{fn: f}
}
func (c *callerInt32ГSliceOfByte) Name() string {
return reflectx.FunctionName(c.fn)
}
func (c *callerInt32ГSliceOfByte) Type() reflect.Type {
return reflect.TypeOf(c.fn)
}
func (c *callerInt32ГSliceOfByte) Call(args []interface{}) []interface{} {
out0 := c.fn(args[0].(int32))
return []interface{}{out0}
}
func (c *callerInt32ГSliceOfByte) Call1x1(arg0 interface{}) interface{} {
return c.fn(arg0.(int32))
}
type callerInt64ГSliceOfByte struct {
fn func(int64) []byte
}
func funcMakerInt64ГSliceOfByte(fn interface{}) reflectx.Func {
f := fn.(func(int64) []byte)
return &callerInt64ГSliceOfByte{fn: f}
}
func (c *callerInt64ГSliceOfByte) Name() string {
return reflectx.FunctionName(c.fn)
}
func (c *callerInt64ГSliceOfByte) Type() reflect.Type {
return reflect.TypeOf(c.fn)
}
func (c *callerInt64ГSliceOfByte) Call(args []interface{}) []interface{} {
out0 := c.fn(args[0].(int64))
return []interface{}{out0}
}
func (c *callerInt64ГSliceOfByte) Call1x1(arg0 interface{}) interface{} {
return c.fn(arg0.(int64))
}
type callerReflect۰TypeSliceOfByteГTypex۰TError struct {
fn func(reflect.Type, []byte) (typex.T, error)
}
func funcMakerReflect۰TypeSliceOfByteГTypex۰TError(fn interface{}) reflectx.Func {
f := fn.(func(reflect.Type, []byte) (typex.T, error))
return &callerReflect۰TypeSliceOfByteГTypex۰TError{fn: f}
}
func (c *callerReflect۰TypeSliceOfByteГTypex۰TError) Name() string {
return reflectx.FunctionName(c.fn)
}
func (c *callerReflect۰TypeSliceOfByteГTypex۰TError) Type() reflect.Type {
return reflect.TypeOf(c.fn)
}
func (c *callerReflect۰TypeSliceOfByteГTypex۰TError) Call(args []interface{}) []interface{} {
out0, out1 := c.fn(args[0].(reflect.Type), args[1].([]byte))
return []interface{}{out0, out1}
}
func (c *callerReflect۰TypeSliceOfByteГTypex۰TError) Call2x2(arg0, arg1 interface{}) (interface{}, interface{}) {
return c.fn(arg0.(reflect.Type), arg1.([]byte))
}
type callerSliceOfByteГInt32 struct {
fn func([]byte) int32
}
func funcMakerSliceOfByteГInt32(fn interface{}) reflectx.Func {
f := fn.(func([]byte) int32)
return &callerSliceOfByteГInt32{fn: f}
}
func (c *callerSliceOfByteГInt32) Name() string {
return reflectx.FunctionName(c.fn)
}
func (c *callerSliceOfByteГInt32) Type() reflect.Type {
return reflect.TypeOf(c.fn)
}
func (c *callerSliceOfByteГInt32) Call(args []interface{}) []interface{} {
out0 := c.fn(args[0].([]byte))
return []interface{}{out0}
}
func (c *callerSliceOfByteГInt32) Call1x1(arg0 interface{}) interface{} {
return c.fn(arg0.([]byte))
}
type callerSliceOfByteГInt64 struct {
fn func([]byte) int64
}
func funcMakerSliceOfByteГInt64(fn interface{}) reflectx.Func {
f := fn.(func([]byte) int64)
return &callerSliceOfByteГInt64{fn: f}
}
func (c *callerSliceOfByteГInt64) Name() string {
return reflectx.FunctionName(c.fn)
}
func (c *callerSliceOfByteГInt64) Type() reflect.Type {
return reflect.TypeOf(c.fn)
}
func (c *callerSliceOfByteГInt64) Call(args []interface{}) []interface{} {
out0 := c.fn(args[0].([]byte))
return []interface{}{out0}
}
func (c *callerSliceOfByteГInt64) Call1x1(arg0 interface{}) interface{} {
return c.fn(arg0.([]byte))
}
type callerSliceOfByteГTypex۰T struct {
fn func([]byte) typex.T
}
func funcMakerSliceOfByteГTypex۰T(fn interface{}) reflectx.Func {
f := fn.(func([]byte) typex.T)
return &callerSliceOfByteГTypex۰T{fn: f}
}
func (c *callerSliceOfByteГTypex۰T) Name() string {
return reflectx.FunctionName(c.fn)
}
func (c *callerSliceOfByteГTypex۰T) Type() reflect.Type {
return reflect.TypeOf(c.fn)
}
func (c *callerSliceOfByteГTypex۰T) Call(args []interface{}) []interface{} {
out0 := c.fn(args[0].([]byte))
return []interface{}{out0}
}
func (c *callerSliceOfByteГTypex۰T) Call1x1(arg0 interface{}) interface{} {
return c.fn(arg0.([]byte))
}
type callerSliceOfByteГUint32 struct {
fn func([]byte) uint32
}
func funcMakerSliceOfByteГUint32(fn interface{}) reflectx.Func {
f := fn.(func([]byte) uint32)
return &callerSliceOfByteГUint32{fn: f}
}
func (c *callerSliceOfByteГUint32) Name() string {
return reflectx.FunctionName(c.fn)
}
func (c *callerSliceOfByteГUint32) Type() reflect.Type {
return reflect.TypeOf(c.fn)
}
func (c *callerSliceOfByteГUint32) Call(args []interface{}) []interface{} {
out0 := c.fn(args[0].([]byte))
return []interface{}{out0}
}
func (c *callerSliceOfByteГUint32) Call1x1(arg0 interface{}) interface{} {
return c.fn(arg0.([]byte))
}
type callerSliceOfByteГUint64 struct {
fn func([]byte) uint64
}
func funcMakerSliceOfByteГUint64(fn interface{}) reflectx.Func {
f := fn.(func([]byte) uint64)
return &callerSliceOfByteГUint64{fn: f}
}
func (c *callerSliceOfByteГUint64) Name() string {
return reflectx.FunctionName(c.fn)
}
func (c *callerSliceOfByteГUint64) Type() reflect.Type {
return reflect.TypeOf(c.fn)
}
func (c *callerSliceOfByteГUint64) Call(args []interface{}) []interface{} {
out0 := c.fn(args[0].([]byte))
return []interface{}{out0}
}
func (c *callerSliceOfByteГUint64) Call1x1(arg0 interface{}) interface{} {
return c.fn(arg0.([]byte))
}
type callerTypex۰TГSliceOfByte struct {
fn func(typex.T) []byte
}
func funcMakerTypex۰TГSliceOfByte(fn interface{}) reflectx.Func {
f := fn.(func(typex.T) []byte)
return &callerTypex۰TГSliceOfByte{fn: f}
}
func (c *callerTypex۰TГSliceOfByte) Name() string {
return reflectx.FunctionName(c.fn)
}
func (c *callerTypex۰TГSliceOfByte) Type() reflect.Type {
return reflect.TypeOf(c.fn)
}
func (c *callerTypex۰TГSliceOfByte) Call(args []interface{}) []interface{} {
out0 := c.fn(args[0].(typex.T))
return []interface{}{out0}
}
func (c *callerTypex۰TГSliceOfByte) Call1x1(arg0 interface{}) interface{} {
return c.fn(arg0.(typex.T))
}
type callerUint32ГSliceOfByte struct {
fn func(uint32) []byte
}
func funcMakerUint32ГSliceOfByte(fn interface{}) reflectx.Func {
f := fn.(func(uint32) []byte)
return &callerUint32ГSliceOfByte{fn: f}
}
func (c *callerUint32ГSliceOfByte) Name() string {
return reflectx.FunctionName(c.fn)
}
func (c *callerUint32ГSliceOfByte) Type() reflect.Type {
return reflect.TypeOf(c.fn)
}
func (c *callerUint32ГSliceOfByte) Call(args []interface{}) []interface{} {
out0 := c.fn(args[0].(uint32))
return []interface{}{out0}
}
func (c *callerUint32ГSliceOfByte) Call1x1(arg0 interface{}) interface{} {
return c.fn(arg0.(uint32))
}
type callerUint64ГSliceOfByte struct {
fn func(uint64) []byte
}
func funcMakerUint64ГSliceOfByte(fn interface{}) reflectx.Func {
f := fn.(func(uint64) []byte)
return &callerUint64ГSliceOfByte{fn: f}
}
func (c *callerUint64ГSliceOfByte) Name() string {
return reflectx.FunctionName(c.fn)
}
func (c *callerUint64ГSliceOfByte) Type() reflect.Type {
return reflect.TypeOf(c.fn)
}
func (c *callerUint64ГSliceOfByte) Call(args []interface{}) []interface{} {
out0 := c.fn(args[0].(uint64))
return []interface{}{out0}
}
func (c *callerUint64ГSliceOfByte) Call1x1(arg0 interface{}) interface{} {
return c.fn(arg0.(uint64))
}
// DO NOT MODIFY: GENERATED CODE