connection class for storing ip and port