Пример #1
0
func newNode(rpcPort string) (*node, error) {
	ts, err := rpctime.NewClient(rpcPort, time.Second*6) // HL
	if err != nil {
		return nil, err
	}

	n := &node{timeServer: ts} // HL
	n.multiplexer = n.mux()    // HL

	return n, nil
}
Пример #2
0
func newNode(rpcPort string) (*node, error) {
	ts, err := rpctime.NewClient(rpcPort, time.Second*6)
	if err != nil {
		return nil, err
	}

	n := &node{}
	n.timeServer = ts
	n.multiplexer = n.mux()

	return n, nil
}