poi-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dominik Stadler <dominik.stad...@gmx.at>
Subject Re: r1808930 forbidden-api checks and imports
Date Thu, 21 Sep 2017 16:18:57 GMT
Argh,

the import-statement handling is a great sucker in Java in my opinion as
every IDE has a different setting of how they are combined and so every
change flips these back and forth. I need to adjust the settings every time
I create a new project somewhere.

I will disabled the automatic collapsing on my current setup for POI,
hopefully it will stay in place for some time so I do not collapse these
more.

Dominik.

On Thu, Sep 21, 2017 at 5:41 PM, Allison, Timothy B. <tallison@mitre.org>
wrote:

> Dominik,
> Thank you for fixing my new PrintStreams so that the forbidden-api checks
> would pass...head in hands.  I noticed that imports were shortened to
> wildcards.  Should I flip back to listing all?
> Thank you, again!
>
>       Best,
>
>                   Tim
>
> -import java.io.ByteArrayInputStream;
> -import java.io.ByteArrayOutputStream;
> -import java.io.File;
> -import java.io.FileOutputStream;
> -import java.io.IOException;
> -import java.io.OutputStream;
> -import java.io.PrintStream;
> +import java.io.*;
>  import org.junit.AfterClass;
> import org.junit.BeforeClass;
> @@ -39,14 +33,14 @@
>      private static PrintStream SYSTEM_OUT;
>      @BeforeClass
> -    public static void setUp() {
> +    public static void setUp() throws UnsupportedEncodingException {
>          SYSTEM_OUT = System.out;
>          System.setOut(new PrintStream(new OutputStream() {
>              @Override
>              public void write(int b) throws IOException {
>              }
> -        }));
> +        }, false, "UTF-8"));
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message