private static < T > T loadObject ( final InputStream is ) throws IOException { final String xmlString = ReadFileExtensions . inputStream2String ( is ) ; final T object = XmlToObjectExtensions . toObjectWithXStream ( xmlString ) ; return object ; }
Load from the given input stream that should represent an xml file and transform it to the generic type object .