2017-10-31 10:27:26 +00:00
|
|
|
package client
|
|
|
|
|
|
|
|
import (
|
|
|
|
"git.loafle.net/commons_go/rpc"
|
2017-11-01 03:20:52 +00:00
|
|
|
"git.loafle.net/commons_go/rpc/client"
|
2017-10-31 10:27:26 +00:00
|
|
|
)
|
|
|
|
|
2017-11-01 03:20:52 +00:00
|
|
|
func New(addr string, registry rpc.Registry) client.Client {
|
2017-10-31 10:27:26 +00:00
|
|
|
|
|
|
|
ch := NewClientHandler(addr, registry)
|
|
|
|
|
2017-11-01 03:20:52 +00:00
|
|
|
c := client.New(ch)
|
2017-10-31 10:27:26 +00:00
|
|
|
|
|
|
|
return c
|
|
|
|
}
|