extract inetAdddress() method so that it can be used later to make set
inet address more generic.