(tsTypesMap map[reflect.Type]string)
| 540 | } |
| 541 | |
| 542 | func GenerateServiceTypes(tsTypesMap map[reflect.Type]string) error { |
| 543 | for _, serviceObj := range service.ServiceMap { |
| 544 | serviceType := reflect.TypeOf(serviceObj) |
| 545 | for midx := 0; midx < serviceType.NumMethod(); midx++ { |
| 546 | method := serviceType.Method(midx) |
| 547 | err := generateTSMethodTypes(method, tsTypesMap, true) |
| 548 | if err != nil { |
| 549 | return fmt.Errorf("error generating TS method types for %s.%s: %v", serviceType, method.Name, err) |
| 550 | } |
| 551 | } |
| 552 | } |
| 553 | return nil |
| 554 | } |
| 555 | |
| 556 | func GenerateWshServerTypes(tsTypesMap map[reflect.Type]string) error { |
| 557 | GenerateTSType(reflect.TypeOf(wshrpc.RpcOpts{}), tsTypesMap) |
no test coverage detected