/** * Gets a serialized representation of a {@link HostRegistration} * * @param registration * The host registration to marshal * @return the serialized host registration */ public static InputStream toXmlStream(HostRegistration registration) throws IOException { return IOUtils.toInputStream(toXml(registration), "UTF-8"); }