Skip to content

Commit 13baa3d

Browse files
authored
correct typos logger/exception messages (#1584)
1 parent dc8d309 commit 13baa3d

File tree

27 files changed

+38
-38
lines changed

27 files changed

+38
-38
lines changed

jme3-android/src/main/java/com/jme3/input/android/AndroidSensorJoyInput.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ private boolean registerListener(int sensorType) {
163163
if (sensorData.sensor != null) {
164164
if (sensorManager.registerListener(this, sensorData.sensor, sensorData.androidSensorSpeed)) {
165165
sensorData.enabled = true;
166-
logger.log(Level.FINE, "SensorType: {0}, actived: {1}",
166+
logger.log(Level.FINE, "SensorType: {0}, enabled: {1}",
167167
new Object[]{sensorType, sensorData.enabled});
168168
return true;
169169
} else {

jme3-core/src/main/java/com/jme3/anim/tween/Tweens.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -567,7 +567,7 @@ private Method findMethod(Class type, String name, Object... args) {
567567
Class[] paramTypes = m.getParameterTypes();
568568
if (paramTypes.length != args.length + 1) {
569569
if (log.isLoggable(Level.FINE)) {
570-
log.log(Level.FINE, "Param lengths of [" + m + "] differ. method arg count:" + paramTypes.length + " lookging for:" + (args.length + 1));
570+
log.log(Level.FINE, "Param lengths of [" + m + "] differ. method arg count:" + paramTypes.length + " looking for:" + (args.length + 1));
571571
}
572572
continue;
573573
}

jme3-core/src/main/java/com/jme3/animation/AnimControl.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,7 @@ public Skeleton getSkeleton() {
242242
public void addListener(AnimEventListener listener) {
243243
if (listeners.contains(listener)) {
244244
throw new IllegalArgumentException("The given listener is already "
245-
+ "registed at this AnimControl");
245+
+ "registered at this AnimControl");
246246
}
247247

248248
listeners.add(listener);
@@ -257,7 +257,7 @@ public void addListener(AnimEventListener listener) {
257257
public void removeListener(AnimEventListener listener) {
258258
if (!listeners.remove(listener)) {
259259
throw new IllegalArgumentException("The given listener is not "
260-
+ "registed at this AnimControl");
260+
+ "registered at this AnimControl");
261261
}
262262
}
263263

jme3-core/src/main/java/com/jme3/audio/openal/ALAudioRenderer.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -737,7 +737,7 @@ private boolean fillStreamingSource(int sourceId, AudioStream stream, boolean lo
737737
active = fillBuffer(stream, buffer);
738738
if (!active) {
739739
throw new IllegalStateException("Looping streaming source " +
740-
"was rewinded but could not be filled");
740+
"was rewound but could not be filled");
741741
}
742742
}
743743

@@ -779,7 +779,7 @@ private void attachStreamToSource(int sourceId, AudioStream stream, boolean loop
779779
active = fillBuffer(stream, id);
780780
if (!active) {
781781
throw new IllegalStateException("Looping streaming source " +
782-
"was rewinded but could not be filled");
782+
"was rewound but could not be filled");
783783
}
784784
}
785785
if (active) {

jme3-core/src/main/java/com/jme3/cinematic/Cinematic.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -570,7 +570,7 @@ public void fitDuration() {
570570
*/
571571
public CameraNode bindCamera(String cameraName, Camera cam) {
572572
if (cameras.containsKey(cameraName)) {
573-
throw new IllegalArgumentException("Camera " + cameraName + " is already binded to this cinematic");
573+
throw new IllegalArgumentException("Camera " + cameraName + " is already bound to this cinematic");
574574
}
575575
CameraNode node = new CameraNode(cameraName, cam);
576576
node.setControlDir(ControlDirection.SpatialToCamera);

jme3-core/src/main/java/com/jme3/renderer/opengl/GLRenderer.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -653,7 +653,7 @@ public void invalidateState() {
653653

654654
@Override
655655
public void resetGLObjects() {
656-
logger.log(Level.FINE, "Reseting objects and invalidating state");
656+
logger.log(Level.FINE, "Resetting objects and invalidating state");
657657
objManager.resetObjects();
658658
statistics.clearMemory();
659659
invalidateState();
@@ -1755,7 +1755,7 @@ private void checkFrameBufferError() {
17551755
throw new IllegalStateException("Framebuffer object format is "
17561756
+ "unsupported by the video hardware.");
17571757
case GLFbo.GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT_EXT:
1758-
throw new IllegalStateException("Framebuffer has erronous attachment.");
1758+
throw new IllegalStateException("Framebuffer has erroneous attachment.");
17591759
case GLFbo.GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT_EXT:
17601760
throw new IllegalStateException("Framebuffer doesn't have any renderbuffers attached.");
17611761
case GLFbo.GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS_EXT:
@@ -2401,7 +2401,7 @@ private void checkNonPowerOfTwo(Texture tex) {
24012401
}
24022402
break;
24032403
default:
2404-
throw new UnsupportedOperationException("unrecongized texture type");
2404+
throw new UnsupportedOperationException("unrecognized texture type");
24052405
}
24062406
}
24072407

jme3-core/src/main/java/com/jme3/renderer/opengl/TextureUtil.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -351,7 +351,7 @@ public void uploadSubTexture(int target, Image src, int index, int targetX, int
351351
}
352352

353353
if (src.getMipMapSizes() != null) {
354-
throw new UnsupportedOperationException("Updating mip-mappped images is not supported");
354+
throw new UnsupportedOperationException("Updating mip-mapped images is not supported");
355355
}
356356

357357
if (src.getMultiSamples() > 1) {

jme3-core/src/main/java/com/jme3/scene/VertexBuffer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1021,7 +1021,7 @@ public static Buffer createBuffer(Format format, int components, int numElements
10211021
case Double:
10221022
return BufferUtils.createDoubleBuffer(total);
10231023
default:
1024-
throw new UnsupportedOperationException("Unrecoginized buffer format: " + format);
1024+
throw new UnsupportedOperationException("Unrecognized buffer format: " + format);
10251025
}
10261026
}
10271027

jme3-core/src/main/java/com/jme3/shader/Uniform.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2009-2017 jMonkeyEngine
2+
* Copyright (c) 2009-2021 jMonkeyEngine
33
* All rights reserved.
44
*
55
* Redistribution and use in source and binary forms, with or without
@@ -357,7 +357,7 @@ public void setValue(VarType type, Object value){
357357
try {
358358
this.value = value.getClass().newInstance();
359359
} catch (InstantiationException | IllegalAccessException e) {
360-
throw new IllegalArgumentException("Cannot instanciate param of class " + value.getClass().getCanonicalName());
360+
throw new IllegalArgumentException("Cannot instantiate param of class " + value.getClass().getCanonicalName());
361361
}
362362
}
363363
//feed the pivot vec 4 with the correct value

jme3-core/src/main/java/com/jme3/util/MaterialDebugAppState.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -225,8 +225,8 @@ public Material reloadMaterial(Material mat) {
225225
return null;
226226
}
227227

228-
Logger.getLogger(MaterialDebugAppState.class.getName()).log(Level.INFO, "Material succesfully reloaded");
229-
//System.out.println("Material succesfully reloaded");
228+
Logger.getLogger(MaterialDebugAppState.class.getName()).log(Level.INFO, "Material successfully reloaded");
229+
//System.out.println("Material successfully reloaded");
230230
return dummy;
231231
}
232232

jme3-core/src/main/java/com/jme3/util/TangentBinormalGenerator.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -408,7 +408,7 @@ private static void bulkPut(VertexBuffer.Format format, Buffer buf1, Buffer buf2
408408
break;
409409

410410
default:
411-
throw new UnsupportedOperationException("Unrecoginized buffer format: " + format);
411+
throw new UnsupportedOperationException("Unrecognized buffer format: " + format);
412412
}
413413
}
414414

@@ -440,7 +440,7 @@ private static void putValue(VertexBuffer.Format format, Buffer buf1, Buffer buf
440440
((DoubleBuffer) buf1).put(d);
441441
break;
442442
default:
443-
throw new UnsupportedOperationException("Unrecoginized buffer format: " + format);
443+
throw new UnsupportedOperationException("Unrecognized buffer format: " + format);
444444
}
445445
}
446446

@@ -557,7 +557,7 @@ public static TriangleData processTriangle(int[] index,
557557

558558
boolean normalize = false;
559559
if (Math.abs(det) < ZERO_TOLERANCE) {
560-
log.log(Level.WARNING, "Colinear uv coordinates for triangle "
560+
log.log(Level.WARNING, "Collinear uv coordinates for triangle "
561561
+ "[{0}, {1}, {2}]; tex0 = [{3}, {4}], "
562562
+ "tex1 = [{5}, {6}], tex2 = [{7}, {8}]",
563563
new Object[]{index[0], index[1], index[2],

jme3-desktop/src/main/java/com/jme3/input/AWTInput.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2009-2018 jMonkeyEngine
2+
* Copyright (c) 2009-2021 jMonkeyEngine
33
* All rights reserved.
44
*
55
* Redistribution and use in source and binary forms, with or without
@@ -83,7 +83,7 @@ public AWTInput(final AWTContext context) {
8383

8484
public void bind(final Component component) {
8585
this.component = component;
86-
Objects.requireNonNull(this.component, "binded Component cannot be null");
86+
Objects.requireNonNull(this.component, "bound Component cannot be null");
8787
}
8888

8989
public void unbind() {

jme3-examples/src/main/java/jme3test/opencl/TestContextSwitching.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ private void updateInfos() {
158158

159159
@NiftyEventSubscriber(id="ApplyButton")
160160
public void onButton(String id, ButtonClickedEvent event) {
161-
LOG.log(Level.INFO, "Change context: platorm={0}, device={1}", new Object[]{selectedPlatform, selectedDevice});
161+
LOG.log(Level.INFO, "Change context: platform={0}, device={1}", new Object[]{selectedPlatform, selectedDevice});
162162
restart();
163163
}
164164

jme3-networking/src/main/java/com/jme3/network/base/DefaultClient.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -416,7 +416,7 @@ protected void handleError( Throwable t )
416416
// If there are no listeners then close the connection with
417417
// a reason
418418
if( errorListeners.isEmpty() ) {
419-
log.log( Level.SEVERE, "Termining connection due to unhandled error", t );
419+
log.log( Level.SEVERE, "Terminating connection due to unhandled error", t );
420420
DisconnectInfo info = new DisconnectInfo();
421421
info.reason = "Connection Error";
422422
info.error = t;

jme3-networking/src/main/java/com/jme3/network/base/DefaultServer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ public class DefaultServer implements Server
9494
public DefaultServer( String gameName, int version, Kernel reliable, Kernel fast )
9595
{
9696
if( reliable == null )
97-
throw new IllegalArgumentException( "Default server reqiures a reliable kernel instance." );
97+
throw new IllegalArgumentException( "Default server requires a reliable kernel instance." );
9898

9999
this.gameName = gameName;
100100
this.version = version;

jme3-networking/src/main/java/com/jme3/network/base/KernelAdapter.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ protected void createAndDispatch( Envelope env )
231231
for( int i = 0; i < len; i++ ) {
232232
sb.append( "[" + Integer.toHexString(data[i]) + "]" );
233233
}
234-
log.log( Level.FINE, "First 10 bytes of incomplete nessage:" + sb );
234+
log.log( Level.FINE, "First 10 bytes of incomplete message:" + sb );
235235
throw new RuntimeException( "Envelope contained incomplete data:" + env );
236236
}
237237
}

jme3-networking/src/main/java/com/jme3/network/kernel/AbstractKernel.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ protected void reportError( Exception e )
7373
{
7474
// Should really be queued up so the outer thread can
7575
// retrieve them. For now we'll just log it. FIXME
76-
log.log( Level.SEVERE, "Unhanddled kernel error", e );
76+
log.log( Level.SEVERE, "Unhandled kernel error", e );
7777
}
7878

7979
protected void wakeupReader() {

jme3-networking/src/main/java/com/jme3/network/service/rpc/RpcConnection.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ public synchronized Object getResponse() {
247247
wait();
248248
}
249249
} catch( InterruptedException e ) {
250-
throw new RuntimeException("Interrupted waiting for respone to:" + msg, e);
250+
throw new RuntimeException("Interrupted waiting for response to:" + msg, e);
251251
}
252252
if( error != null ) {
253253
throw new RuntimeException("Error calling remote procedure:" + msg + "\n" + error);

jme3-plugins/src/fbx/java/com/jme3/scene/plugins/fbx/RotationOrder.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ private static Quaternion fromEuler(float x, float y, float z, RotationOrder ord
3838
return toQuat(x, Vector3f.UNIT_X, z, Vector3f.UNIT_Z, y, Vector3f.UNIT_Y);
3939
case SPHERIC_XYZ:
4040
default:
41-
throw new IllegalArgumentException("Spheric rotation is unsupported in this importer");
41+
throw new IllegalArgumentException("Spherical rotation is unsupported in this importer");
4242
}
4343
}
4444

jme3-plugins/src/fbx/java/com/jme3/scene/plugins/fbx/file/FbxReader.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ private static Object readArray(ByteBuffer byteBuffer, char type, int bytes) thr
152152
if(encoding == 1)
153153
data = inflate(data);
154154
if(data.length != count * bytes)
155-
throw new IOException("Wrong data lenght. Expected: " + count * bytes + ", got: " + data.length);
155+
throw new IOException("Wrong data length. Expected: " + count * bytes + ", got: " + data.length);
156156
ByteBuffer dis = ByteBuffer.wrap(data).order(ByteOrder.LITTLE_ENDIAN);
157157
switch(type) {
158158
case 'f':

jme3-plugins/src/gltf/java/com/jme3/scene/plugins/gltf/GltfLoader.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -685,7 +685,7 @@ public void readCameras() throws IOException {
685685
Float yfov = getAsFloat(camData, "yfov");
686686
assertNotNull(yfov, "No yfov for perspective camera");
687687
Float znear = getAsFloat(camData, "znear");
688-
assertNotNull(znear, "No znear for perspective camere");
688+
assertNotNull(znear, "No znear for perspective camera");
689689
Float zfar = getAsFloat(camData, "zfar", znear * 1000f);
690690

691691
cam.setFrustumPerspective(yfov * FastMath.RAD_TO_DEG, aspectRatio, znear, zfar);

jme3-plugins/src/main/java/com/jme3/scene/plugins/IrUtils.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -381,7 +381,7 @@ public static Mesh convertIrMeshToJmeMesh(IrMesh mesh) {
381381
if (vertex.boneWeightsIndices != null) {
382382
if (vertex.boneWeightsIndices.length > 4) {
383383
throw new UnsupportedOperationException("Mesh uses more than 4 weights per bone. " +
384-
"Call trimBoneWeights() to allieviate this");
384+
"Call trimBoneWeights() to alleviate this");
385385
}
386386
for (int i = 0; i < vertex.boneWeightsIndices.length; i++) {
387387
boneIndices.put((byte) (vertex.boneWeightsIndices[i].boneIndex & 0xFF));

jme3-terrain/src/main/java/com/jme3/terrain/heightmap/HillHeightMap.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2009-2020 jMonkeyEngine
2+
* Copyright (c) 2009-2021 jMonkeyEngine
33
* All rights reserved.
44
*
55
* Redistribution and use in source and binary forms, with or without
@@ -80,7 +80,7 @@ public HillHeightMap(int size, int iterations, float minRadius,
8080
+ "or minimum radius is greater than maximum radius, "
8181
+ "or power of flattening is below one");
8282
}
83-
logger.fine("Contructing hill heightmap using seed: " + seed);
83+
logger.fine("Constructing hill heightmap using seed: " + seed);
8484
this.size = size;
8585
this.seed = seed;
8686
this.iterations = iterations;

jme3-vr/src/main/java/com/jme3/app/VREnvironment.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -415,7 +415,7 @@ public void atttach(AppState appState, Application application){
415415
} else if (vrBinding == VRConstants.SETTING_VRAPI_OPENVR_LWJGL_VALUE) {
416416
viewmanager = new LWJGLOpenVRViewManager(this);
417417
} else {
418-
logger.severe("Cannot instanciate view manager, unknown VRAPI type: "+vrBinding);
418+
logger.severe("Cannot instantiate view manager, unknown VRAPI type: "+vrBinding);
419419
}
420420
}
421421

@@ -465,7 +465,7 @@ public boolean initialize(){
465465

466466
hardware = new OculusVR(this);
467467
initialized = true;
468-
logger.config("Creating Occulus Rift wrapper [SUCCESS]");
468+
logger.config("Creating Oculus Rift wrapper [SUCCESS]");
469469
} else if (vrBinding == VRConstants.SETTING_VRAPI_OPENVR_LWJGL_VALUE) {
470470

471471
guiManager = new VRGuiManager(this);

jme3-vr/src/main/java/com/jme3/input/vr/lwjgl_openvr/LWJGLOpenVRInput.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -264,7 +264,7 @@ public boolean init() {
264264
posStore[i] = new Vector3f();
265265
cStates[i] = VRControllerState.create();
266266
lastCallAxis[i] = new Vector2f();
267-
logger.config(" Input " + (i + 1) + "/" + VR.k_unMaxTrackedDeviceCount + " binded.");
267+
logger.config(" Input " + (i + 1) + "/" + VR.k_unMaxTrackedDeviceCount + " bound.");
268268
}
269269

270270
return true;

jme3-vr/src/main/java/com/jme3/input/vr/oculus/OculusVR.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ public void invoke(long userData, int level, long message) {
215215
+ "\t Resolution (total): " + resolutionW + "," + resolutionH);
216216

217217
if (resolutionW == 0) {
218-
LOGGER.severe("HMD witdth=0 : aborting");
218+
LOGGER.severe("HMD width=0 : aborting");
219219
return false; // TODO fix memory leak - destroy() is not called
220220
}
221221

jme3-vr/src/main/java/com/jme3/input/vr/openvr/OpenVRInput.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ public boolean init() {
280280
lastCallAxis[i] = new Vector2f();
281281
needsNewVelocity[i] = true;
282282
needsNewAngVelocity[i] = true;
283-
logger.config(" Input "+(i+1)+"/"+JOpenVRLibrary.k_unMaxTrackedDeviceCount+" binded.");
283+
logger.config(" Input "+(i+1)+"/"+JOpenVRLibrary.k_unMaxTrackedDeviceCount+" bound.");
284284
}
285285

286286
return true;

0 commit comments

Comments
 (0)