Completed the Network class