Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove static variables #513

Merged
merged 4 commits into from
Aug 27, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"java.configuration.updateBuildConfiguration": "interactive",
"[java]": {
"editor.defaultFormatter": "redhat.java",
"editor.defaultFormatter": "serikb.google-java-format",
"editor.formatOnSave": true,
},
"java.format.settings.url": "https://raw.githubusercontent.com/google/styleguide/gh-pages/eclipse-java-google-style.xml",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,6 @@
public class CricondenbarAnalyser extends MeasurementDeviceBaseClass {
private static final long serialVersionUID = 1000;
static Logger logger = LogManager.getLogger(CricondenbarAnalyser.class);

protected int streamNumber = 0;

/** Constant <code>numberOfStreams=0</code>. */
protected static int numberOfStreams = 0;
protected StreamInterface stream = null;

/**
Expand All @@ -40,8 +35,6 @@ public CricondenbarAnalyser() {}
*/
public CricondenbarAnalyser(StreamInterface stream) {
this.stream = stream;
numberOfStreams++;
streamNumber = numberOfStreams;
unit = "K";
setConditionAnalysisMaxDeviation(1.0);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,6 @@
public class HydrateEquilibriumTemperatureAnalyser extends MeasurementDeviceBaseClass {
private static final long serialVersionUID = 1000;
static Logger logger = LogManager.getLogger(HydrateEquilibriumTemperatureAnalyser.class);

protected int streamNumber = 0;
/** Constant <code>numberOfStreams=0</code> */
protected static int numberOfStreams = 0;
protected StreamInterface stream = null;
private double referencePressure = 0;

Expand All @@ -40,8 +36,6 @@ public HydrateEquilibriumTemperatureAnalyser() {}
*/
public HydrateEquilibriumTemperatureAnalyser(StreamInterface stream) {
this.stream = stream;
numberOfStreams++;
streamNumber = numberOfStreams;
unit = "K";
setConditionAnalysisMaxDeviation(1.0);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,6 @@
*/
public class MolarMassAnalyser extends MeasurementDeviceBaseClass {
private static final long serialVersionUID = 1000;

protected int streamNumber = 0;
/** Constant <code>numberOfStreams=0</code> */
protected static int numberOfStreams = 0;
protected StreamInterface stream = null;

/**
Expand All @@ -39,8 +35,6 @@ public MolarMassAnalyser() {
public MolarMassAnalyser(StreamInterface stream) {
this();
this.stream = stream;
numberOfStreams++;
streamNumber = numberOfStreams;
}

/** {@inheritDoc} */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,6 @@
*/
public class PressureTransmitter extends MeasurementDeviceBaseClass {
private static final long serialVersionUID = 1000;

protected int streamNumber = 0;
/** Constant <code>numberOfStreams=0</code> */
protected static int numberOfStreams = 0;
protected StreamInterface stream = null;

/**
Expand All @@ -39,8 +35,6 @@ public PressureTransmitter() {
public PressureTransmitter(StreamInterface stream) {
this();
this.stream = stream;
numberOfStreams++;
streamNumber = numberOfStreams;
}

/** {@inheritDoc} */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,6 @@
*/
public class TemperatureTransmitter extends MeasurementDeviceBaseClass {
private static final long serialVersionUID = 1000;

protected int streamNumber = 0;
/** Constant <code>numberOfStreams=0</code> */
protected static int numberOfStreams = 0;
protected StreamInterface stream = null;

public TemperatureTransmitter() {
Expand All @@ -40,8 +36,6 @@ public TemperatureTransmitter() {
public TemperatureTransmitter(StreamInterface stream) {
this();
this.stream = stream;
numberOfStreams++;
streamNumber = numberOfStreams;
}

/** {@inheritDoc} */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,6 @@
*/
public class VolumeFlowTransmitter extends MeasurementDeviceBaseClass {
private static final long serialVersionUID = 1000;

protected int streamNumber = 0;
/** Constant <code>numberOfStreams=0</code> */
protected static int numberOfStreams = 0;
protected StreamInterface stream = null;
private int measuredPhaseNumber = 0;

Expand All @@ -36,8 +32,6 @@ public VolumeFlowTransmitter() {}
*/
public VolumeFlowTransmitter(StreamInterface stream) {
this.stream = stream;
numberOfStreams++;
streamNumber = numberOfStreams;
name = "volume flow rate";
unit = "m^3/hr";
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,6 @@
*/
public class WaterContentAnalyser extends MeasurementDeviceBaseClass {
private static final long serialVersionUID = 1000;

protected int streamNumber = 0;
/** Constant <code>numberOfStreams=0</code> */
protected static int numberOfStreams = 0;
protected StreamInterface stream = null;

/**
Expand All @@ -35,8 +31,6 @@ public WaterContentAnalyser() {}
*/
public WaterContentAnalyser(StreamInterface stream) {
this.stream = stream;
numberOfStreams++;
streamNumber = numberOfStreams;
name = "water analyser";
unit = "kg/day";
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,6 @@
public class WaterDewPointAnalyser extends MeasurementDeviceBaseClass {
private static final long serialVersionUID = 1000;
static Logger logger = LogManager.getLogger(WaterDewPointAnalyser.class);

protected int streamNumber = 0;
/** Constant <code>numberOfStreams=0</code> */
protected static int numberOfStreams = 0;
protected StreamInterface stream = null;
private double referencePressure = 70.0;
private String method = "Bukacek";
Expand All @@ -42,8 +38,6 @@ public WaterDewPointAnalyser() {}
*/
public WaterDewPointAnalyser(StreamInterface stream) {
this.stream = stream;
numberOfStreams++;
streamNumber = numberOfStreams;
unit = "K";
setConditionAnalysisMaxDeviation(1.0);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public GasTurbine() {
public GasTurbine(String name) {
super(name);
// needs to be changed to gas tubing mechanical design
SystemInterface airThermoSystem = neqsim.thermo.Fluid.create("combustion air");
SystemInterface airThermoSystem = new neqsim.thermo.Fluid().create("combustion air");
airThermoSystem.createDatabase(true);
// airThermoSystem.display();
airStream = new Stream("airStream", airThermoSystem);
Expand Down
Loading