May 5, 2017

[HDGEM] Creating sample test file in Java

    private static File createSampleFile() throws IOException {
        File file = File.createTempFile("aws-java-sdk-", ".txt");
        file.deleteOnExit();

        Writer writer = new OutputStreamWriter(new FileOutputStream(file));
        writer.write("abcdefghijklmnopqrstuvwxyz\n");
        writer.write("01234567890112345678901234\n");
        writer.write("[email protected]#$%^&*()-=[]{};':',.<>/?\n");
        writer.write("01234567890112345678901234\n");
        writer.write("abcdefghijklmnopqrstuvwxyz\n");
        writer.close();

        return file;


--
Posted By Blogger to HDGEM at 5/05/2017 09:10:00 AM
Post a Comment

Featured Post

Datasets

Google Tables helps you search thousands of public Fusion Tables, or millions of public tables from around the web you can import to Fusio...