factored out a more opaque network object