Skip to content

Commit

Permalink
lib: add "this." qualifier to LHS of assignments
Browse files Browse the repository at this point in the history
  • Loading branch information
stephengold committed Sep 28, 2023
1 parent e65b1a0 commit 587db81
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 24 deletions.
18 changes: 9 additions & 9 deletions WesLibrary/src/main/java/jme3utilities/wes/RotationCurve.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright (c) 2017-2022, Stephen Gold
Copyright (c) 2017-2023, Stephen Gold
All rights reserved.
Redistribution and use in source and binary forms, with or without
Expand Down Expand Up @@ -220,8 +220,8 @@ void setControlPoints(
Validate.nonNull(controlPoint1, "control point 1");
Validate.nonNull(controlPoint2, "control point 2");

controlPoint1s[index] = controlPoint1;
controlPoint2s[index] = controlPoint2;
this.controlPoint1s[index] = controlPoint1;
this.controlPoint2s[index] = controlPoint2;
}

/**
Expand All @@ -232,10 +232,10 @@ void setControlPoints(
void setLastIndex(int newLastIndex) {
Validate.nonNegative(newLastIndex, "new last index");

controlPoint1s = new Quaternion[newLastIndex + 1];
controlPoint2s = new Quaternion[newLastIndex + 1];
endValues = new Quaternion[newLastIndex + 1];
intervalDurations = new float[newLastIndex + 1];
this.controlPoint1s = new Quaternion[newLastIndex + 1];
this.controlPoint2s = new Quaternion[newLastIndex + 1];
this.endValues = new Quaternion[newLastIndex + 1];
this.intervalDurations = new float[newLastIndex + 1];
}

/**
Expand All @@ -249,7 +249,7 @@ void setParameters(int index, Quaternion endValue, float intervalDuration) {
Validate.nonNull(endValue, "end value");
Validate.positive(intervalDuration, "interval duration");

endValues[index] = endValue;
intervalDurations[index] = intervalDuration;
this.endValues[index] = endValue;
this.intervalDurations[index] = intervalDuration;
}
}
30 changes: 15 additions & 15 deletions WesLibrary/src/main/java/jme3utilities/wes/VectorCurve.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright (c) 2017-2022, Stephen Gold
Copyright (c) 2017-2023, Stephen Gold
All rights reserved.
Redistribution and use in source and binary forms, with or without
Expand Down Expand Up @@ -279,8 +279,8 @@ void setAuxPoints(int index, Vector3f auxPoint1, Vector3f auxPoint2) {
Validate.nonNull(auxPoint1, "aux point 1");
Validate.nonNull(auxPoint2, "aux point 2");

aux1s[index] = auxPoint1;
aux2s[index] = auxPoint2;
this.aux1s[index] = auxPoint1;
this.aux2s[index] = auxPoint2;
}

/**
Expand All @@ -293,9 +293,9 @@ void setAuxPoints(int index, Vector3f auxPoint1, Vector3f auxPoint2) {
* @param dt23 square root of following interval's distance (≥0)
*/
void setDts(int index, float dt01, float dt12, float dt23) {
dt01s[index] = dt01;
dt12s[index] = dt12;
dt23s[index] = dt23;
this.dt01s[index] = dt01;
this.dt12s[index] = dt12;
this.dt23s[index] = dt23;
}

/**
Expand All @@ -308,14 +308,14 @@ void setLastIndex(int newLastIndex, boolean allocateDts) {
Validate.nonNegative(newLastIndex, "new last index");

int numSamples = newLastIndex + 1;
aux1s = new Vector3f[numSamples];
aux2s = new Vector3f[numSamples];
endValues = new Vector3f[numSamples];
intervalDurations = new float[numSamples];
this.aux1s = new Vector3f[numSamples];
this.aux2s = new Vector3f[numSamples];
this.endValues = new Vector3f[numSamples];
this.intervalDurations = new float[numSamples];
if (allocateDts) {
dt01s = new float[numSamples];
dt12s = new float[numSamples];
dt23s = new float[numSamples];
this.dt01s = new float[numSamples];
this.dt12s = new float[numSamples];
this.dt23s = new float[numSamples];
}
}

Expand All @@ -330,7 +330,7 @@ void setParameters(int index, Vector3f endValue, float intervalDuration) {
Validate.nonNull(endValue, "end value");
Validate.positive(intervalDuration, "interval duration");

endValues[index] = endValue;
intervalDurations[index] = intervalDuration;
this.endValues[index] = endValue;
this.intervalDurations[index] = intervalDuration;
}
}

0 comments on commit 587db81

Please sign in to comment.