added support for cookie in RestClientTarget.

also addded a constructor to RestClienException,
taking only a string arg.