Cleanup (formatting)

This commit is contained in:
Roman Shevchenko
2016-04-13 19:39:56 +02:00
parent 08cd13316d
commit eeb5bda926
3 changed files with 8 additions and 17 deletions
@@ -199,18 +199,9 @@ public class BaseOSProcessHandler extends ProcessHandler implements TaskExecutor
@NotNull
private Reader createInputStreamReader(@NotNull InputStream streamToRead) {
Charset charset = charsetNotNull();
return new BaseInputStreamReader(streamToRead, charset);
}
@NotNull
private Charset charsetNotNull() {
Charset charset = getCharset();
if (charset == null) {
// use default charset
charset = Charset.defaultCharset();
}
return charset;
if (charset == null) charset = Charset.defaultCharset();
return new BaseInputStreamReader(streamToRead, charset);
}
@Override
@@ -1,5 +1,5 @@
/*
* Copyright 2000-2015 JetBrains s.r.o.
* Copyright 2000-2016 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -36,7 +36,7 @@ public abstract class BaseDataReader {
private Future<?> myFinishedFuture;
public BaseDataReader(SleepingPolicy sleepingPolicy) {
mySleepingPolicy = sleepingPolicy != null ? sleepingPolicy: SleepingPolicy.SIMPLE;
mySleepingPolicy = sleepingPolicy != null ? sleepingPolicy : SleepingPolicy.SIMPLE;
}
/** @deprecated use {@link #start(String)} instead (to be removed in IDEA 17) */
@@ -28,13 +28,13 @@ import java.nio.charset.Charset;
public class BaseInputStreamReader extends InputStreamReader {
private final InputStream myInputStream;
public BaseInputStreamReader(@NotNull InputStream in, @NotNull Charset cs) {
super(in, cs);
public BaseInputStreamReader(@NotNull InputStream in) {
super(in);
myInputStream = in;
}
public BaseInputStreamReader(InputStream in) {
super(in);
public BaseInputStreamReader(@NotNull InputStream in, @NotNull Charset cs) {
super(in, cs);
myInputStream = in;
}