To some extent this feature is supported
Because the argument is `[]interface{}`
So you can call this method like this
#### java code
```java
public interface UserProvider {
User GetUser(String userId);
User GetUser(String userId,String userName);
}
```
`golang` code does not need to be modified, just need to call this
``` go
//GetUser(String)
user := &User{}
//GetUser(String,String)
user2 := &User{}
err := userProvider.GetUser(context.TODO(), []interface{}{"A001"}, user)
if err != nil {
panic(err)
}
err1 := userProvider.GetUser(context.TODO(), []interface{}{"A002",
"likai"}, user2)
if err1 != nil {
panic(err1)
}
println("GetUser(String userId) result: %v\n", user)
println("GetUser(String userId,String userName) result: %v\n", user2)
```
### Console output
``` console
start to test dubbo
2019-10-23T20:00:15.156+0800 INFO dubbo/pool.go:81 client init ok
2019-10-23T20:00:15.157+0800 INFO proxy/proxy.go:130
[makeDubboCallProxy] result: &{A001 zhangsan 18 2019-10-23 20:00:15.157 +0800
CST}, err: <nil>
2019-10-23T20:00:15.158+0800 INFO proxy/proxy.go:130
[makeDubboCallProxy] result: &{A002 likai 22 2019-10-23 20:00:15.158 +0800
CST}, err: <nil>
```
[ Full content available at: https://github.com/apache/dubbo-go/issues/192 ]
This message was relayed via gitbox.apache.org for
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]