public String encode ( String fileUrl ) { String file = getFilePathFromWikiUrl ( fileUrl ) ; try { byte [ ] content = IOUtils . toByteArray ( new FileInputStream ( file ) ) ; return base64Encode ( content ) ; } catch ( IOException e ) { throw new SlimFixtureException ( "Unable to read: " + file , e ) ; } }
Gets the content of specified file base64 encoded .