diff --git a/core/src/de/congrace/exp4j/ExpressionBuilder.java b/core/src/de/congrace/exp4j/ExpressionBuilder.java index 66eaa6fb6..0b9fecc62 100644 --- a/core/src/de/congrace/exp4j/ExpressionBuilder.java +++ b/core/src/de/congrace/exp4j/ExpressionBuilder.java @@ -105,7 +105,7 @@ public class ExpressionBuilder { /** * set the variables names used in the expression without setting their - * values. Usefull for building an expression before you know the variable values. + * values. Useful for building an expression before you know the variable values. * * @param variableNames * vararg {@link String} of the variable names used in the diff --git a/core/src/de/congrace/exp4j/FunctionToken.java b/core/src/de/congrace/exp4j/FunctionToken.java index 1d155048d..385ecda7a 100644 --- a/core/src/de/congrace/exp4j/FunctionToken.java +++ b/core/src/de/congrace/exp4j/FunctionToken.java @@ -143,7 +143,7 @@ class FunctionToken extends CalculationToken { * * get the {@link Function} * - * @return the correspoding {@link Function} + * @return the corresponding {@link Function} */ Function getFunction() { return function; diff --git a/core/src/net/sf/openrocket/appearance/Decal.java b/core/src/net/sf/openrocket/appearance/Decal.java index 412cdcd3d..2e0619ee4 100644 --- a/core/src/net/sf/openrocket/appearance/Decal.java +++ b/core/src/net/sf/openrocket/appearance/Decal.java @@ -35,11 +35,11 @@ public class Decal { private final EdgeMode mode; /** - * Builds a new decal with the given itens + * Builds a new decal with the given items * - * @param offset The offset of the decal, in coordinate obejct format + * @param offset The offset of the decal, in coordinate object format * @param center The position of the center of the decal, in coordinate object format - * @param scale The scale of the decal, in coordinate obejct format + * @param scale The scale of the decal, in coordinate object format * @param rotation Rotation of the decal, in radians * @param image The image itself * @param mode The description of Edge behaviour diff --git a/core/src/net/sf/openrocket/appearance/DecalImage.java b/core/src/net/sf/openrocket/appearance/DecalImage.java index 77a74010f..cd12cc69e 100644 --- a/core/src/net/sf/openrocket/appearance/DecalImage.java +++ b/core/src/net/sf/openrocket/appearance/DecalImage.java @@ -8,7 +8,7 @@ import java.io.InputStream; import net.sf.openrocket.util.ChangeSource; /** - * Interface to handle image files for declas + * Interface to handle image files for decals * */ public interface DecalImage extends ChangeSource, Comparable { diff --git a/core/src/net/sf/openrocket/communication/UpdateInfoRetriever.java b/core/src/net/sf/openrocket/communication/UpdateInfoRetriever.java index 654ac0a93..804d7eb49 100644 --- a/core/src/net/sf/openrocket/communication/UpdateInfoRetriever.java +++ b/core/src/net/sf/openrocket/communication/UpdateInfoRetriever.java @@ -131,7 +131,7 @@ public class UpdateInfoRetriever { } /** - * check if the string is formated as an update list header + * check if the string is formatted as an update list header * @param str the string to be checked * @return true if str is a header, false otherwise */ @@ -250,7 +250,7 @@ public class UpdateInfoRetriever { /** * checks if a line contains an update information * @param line the line to be checked - * @return true if the line caontain an update information + * @return true if the line contain an update information * false otherwise */ private boolean isUpdateInfo(String line) { @@ -386,7 +386,7 @@ public class UpdateInfoRetriever { /** * builds the default url for fetching updates - * @return the string with an url for fethcing updates + * @return the string with an url for fetching updates */ private String getUrl() { return Communicator.UPDATE_INFO_URL + "?" + Communicator.VERSION_PARAM + "=" diff --git a/core/src/net/sf/openrocket/database/motor/ThrustCurveMotorSet.java b/core/src/net/sf/openrocket/database/motor/ThrustCurveMotorSet.java index 782c82e32..b48ed3344 100644 --- a/core/src/net/sf/openrocket/database/motor/ThrustCurveMotorSet.java +++ b/core/src/net/sf/openrocket/database/motor/ThrustCurveMotorSet.java @@ -100,7 +100,7 @@ public class ThrustCurveMotorSet implements Comparable { * @param motor the motor to be checked * @param digest the digest of the motor * @param m the current motor being checked with - * @return wheter the motor is or no + * @return whether the motor is or no */ private boolean isMotorPresent(ThrustCurveMotor motor, final String digest, Motor m) { return digest.equals(digestMap.get(m)) && @@ -129,7 +129,7 @@ public class ThrustCurveMotorSet implements Comparable { /** - * adds the standard delay if aplicable + * adds the standard delay if applicable * @param motor the motor to be considered */ private void addStandardDelays(ThrustCurveMotor motor) { @@ -181,7 +181,7 @@ public class ThrustCurveMotorSet implements Comparable { /** * checks if the given motor is the first one - * the ifrst motor inserted is what will difine the rest of the motors in the set + * the first motor inserted is what will define the rest of the motors in the set * @param motor the motor to be checked */ private void checkFirstInsertion(ThrustCurveMotor motor) { diff --git a/core/src/net/sf/openrocket/document/DecalRegistry.java b/core/src/net/sf/openrocket/document/DecalRegistry.java index 9b523d066..7f512bff9 100644 --- a/core/src/net/sf/openrocket/document/DecalRegistry.java +++ b/core/src/net/sf/openrocket/document/DecalRegistry.java @@ -230,8 +230,8 @@ public class DecalRegistry { } /** - * sercha - * @param file + * Find decal that has file {file} as source + * @param file decal source file * @return */ private DecalImageImpl findDecalForFile(File file) { @@ -272,7 +272,7 @@ public class DecalRegistry { /** * Makes a unique name for saving decal files in case the name already exists * @param name the name of the decal - * @return the name formated and unique + * @return the name formatted and unique */ private String makeUniqueName(String name) { diff --git a/core/src/net/sf/openrocket/document/OpenRocketDocument.java b/core/src/net/sf/openrocket/document/OpenRocketDocument.java index b531cc2c3..dd70d4be3 100644 --- a/core/src/net/sf/openrocket/document/OpenRocketDocument.java +++ b/core/src/net/sf/openrocket/document/OpenRocketDocument.java @@ -120,13 +120,13 @@ public class OpenRocketDocument implements ComponentChangeListener { */ public void addCustomExpression(CustomExpression expression) { if (customExpressions.contains(expression)) { - log.info(Markers.USER_MARKER, "Could not add custom expression " + expression.getName() + " to document as document alerady has a matching expression."); + log.info(Markers.USER_MARKER, "Could not add custom expression " + expression.getName() + " to document as document already has a matching expression."); } customExpressions.add(expression); } /** - * remves + * Removes custom expression from the document * @param expression */ public void removeCustomExpression(CustomExpression expression) { @@ -418,7 +418,7 @@ public class OpenRocketDocument implements ComponentChangeListener { /** * removes all simulations with the specific configId - * @param configId the Flight Configuration Id that dictates which simulations shoul be removed + * @param configId the Flight Configuration Id that dictates which simulations should be removed */ private void removeSimulations(FlightConfigurationId configId) { for (Simulation s : getSimulations()) { diff --git a/core/src/net/sf/openrocket/document/Simulation.java b/core/src/net/sf/openrocket/document/Simulation.java index 277431ed8..50047e07f 100644 --- a/core/src/net/sf/openrocket/document/Simulation.java +++ b/core/src/net/sf/openrocket/document/Simulation.java @@ -438,7 +438,7 @@ public class Simulation implements ChangeSource, Cloneable { } /** - * Return true if this simulation contains plotable flight data. + * Return true if this simulation contains plottable flight data. * * @return */ diff --git a/core/src/net/sf/openrocket/file/CSVExport.java b/core/src/net/sf/openrocket/file/CSVExport.java index 35e2d1608..6f821a381 100644 --- a/core/src/net/sf/openrocket/file/CSVExport.java +++ b/core/src/net/sf/openrocket/file/CSVExport.java @@ -93,7 +93,7 @@ public class CSVExport { // Number of data points int n = branch.getLength(); - // Flight events in occurrance order + // Flight events in occurrence order List events = branch.getEvents(); Collections.sort(events); int eventPosition = 0; diff --git a/core/src/net/sf/openrocket/file/GeneralRocketSaver.java b/core/src/net/sf/openrocket/file/GeneralRocketSaver.java index 9df2abf73..4d4d5863e 100644 --- a/core/src/net/sf/openrocket/file/GeneralRocketSaver.java +++ b/core/src/net/sf/openrocket/file/GeneralRocketSaver.java @@ -147,7 +147,7 @@ public class GeneralRocketSaver { private void save(String fileName, OutputStream output, OpenRocketDocument document, StorageOptions options) throws IOException { - // For now, we don't save decal inforamtion in ROCKSIM files, so don't do anything + // For now, we don't save decal information in ROCKSIM files, so don't do anything // which follows. // TODO - add support for decals in ROCKSIM files? if (options.getFileType() == FileType.ROCKSIM) { diff --git a/core/src/net/sf/openrocket/file/openrocket/OpenRocketSaver.java b/core/src/net/sf/openrocket/file/openrocket/OpenRocketSaver.java index c4514b4ba..e55f1d366 100644 --- a/core/src/net/sf/openrocket/file/openrocket/OpenRocketSaver.java +++ b/core/src/net/sf/openrocket/file/openrocket/OpenRocketSaver.java @@ -234,7 +234,7 @@ public class OpenRocketSaver extends RocketSaver { /** - * Finds a getElements method somewhere in the *saver class hiearchy corresponding to the given component. + * Finds a getElements method somewhere in the *saver class hierarchy corresponding to the given component. */ private static Reflection.Method findGetElementsMethod(RocketComponent component) { String currentclassname; diff --git a/core/src/net/sf/openrocket/file/rocksim/importt/RingHandler.java b/core/src/net/sf/openrocket/file/rocksim/importt/RingHandler.java index 96bcd1bdf..dd3815944 100644 --- a/core/src/net/sf/openrocket/file/rocksim/importt/RingHandler.java +++ b/core/src/net/sf/openrocket/file/rocksim/importt/RingHandler.java @@ -184,7 +184,7 @@ class RingHandler extends PositionDependentHandler { super.endHandler(element, attributes, content, warnings); // The XML element in Rocksim design file is used for many types of components, unfortunately. - // Additional subelements are used to indicate the type of the rocket component. When parsing using SAX + // Additional sub-elements are used to indicate the type of the rocket component. When parsing using SAX // this poses a problem because we can't "look ahead" to see what type is being represented at the start // of parsing - something that would be nice to do so that we can instantiate the correct OR component // at the start, then just call setters for the appropriate data. diff --git a/core/src/net/sf/openrocket/file/simplesax/ElementHandler.java b/core/src/net/sf/openrocket/file/simplesax/ElementHandler.java index cdbbe1d61..de963949f 100644 --- a/core/src/net/sf/openrocket/file/simplesax/ElementHandler.java +++ b/core/src/net/sf/openrocket/file/simplesax/ElementHandler.java @@ -36,7 +36,7 @@ public interface ElementHandler { * and all of its contents is to be ignored. *

* Note that this method may also return this, in which case this - * handler will also handle the subelement. + * handler will also handle the sub-element. * * @param element the element name. * @param attributes attributes of the element. diff --git a/core/src/net/sf/openrocket/file/simplesax/NullElementHandler.java b/core/src/net/sf/openrocket/file/simplesax/NullElementHandler.java index 2cc86be3c..302ee91c9 100644 --- a/core/src/net/sf/openrocket/file/simplesax/NullElementHandler.java +++ b/core/src/net/sf/openrocket/file/simplesax/NullElementHandler.java @@ -9,7 +9,7 @@ import org.xml.sax.SAXException; /** * A singleton element handler that does not accept any content in the element - * except whitespace text. All subelements are ignored and a warning is produced + * except whitespace text. All sub-elements are ignored and a warning is produced * of them. It ignores any attributes. *

* This class can be used for elements that have no content but contain attributes. diff --git a/core/src/net/sf/openrocket/masscalc/MassCalculation.java b/core/src/net/sf/openrocket/masscalc/MassCalculation.java index 3d4242dc8..b54d58aa1 100644 --- a/core/src/net/sf/openrocket/masscalc/MassCalculation.java +++ b/core/src/net/sf/openrocket/masscalc/MassCalculation.java @@ -242,7 +242,7 @@ public class MassCalculation { double clusterIt = motorConfig.getUnitLongitudinalInertia()*instanceCount*eachMass; - // if more than 1 moter => motors are not an the centerline => adjust via parallel-axis theorem + // if more than 1 motor => motors are not at the centerline => adjust via parallel-axis theorem double clusterIr = clusterBaseIr; if( 1 < instanceCount ){ for( Coordinate coord : offsets ){ diff --git a/core/src/net/sf/openrocket/optimization/general/FunctionCache.java b/core/src/net/sf/openrocket/optimization/general/FunctionCache.java index 69c42d790..fbe6beda4 100644 --- a/core/src/net/sf/openrocket/optimization/general/FunctionCache.java +++ b/core/src/net/sf/openrocket/optimization/general/FunctionCache.java @@ -2,7 +2,7 @@ package net.sf.openrocket.optimization.general; /** * A storage of cached values of a function. The purpose of this class is to - * cache function values between optimization runs. Subinterfaces may provide + * cache function values between optimization runs. Sub-interfaces may provide * additional functionality. * * @author Sampo Niskanen diff --git a/core/src/net/sf/openrocket/optimization/general/Point.java b/core/src/net/sf/openrocket/optimization/general/Point.java index 9b2bece88..19e615a86 100644 --- a/core/src/net/sf/openrocket/optimization/general/Point.java +++ b/core/src/net/sf/openrocket/optimization/general/Point.java @@ -148,7 +148,7 @@ public final class Point { /** * Return the squared length of this coordinate. * - * @return the square of the length of thie coordinate. + * @return the square of the length of the coordinate. */ public double length2() { if (length2 < 0) { diff --git a/core/src/net/sf/openrocket/optimization/general/multidim/MultidirectionalSearchOptimizer.java b/core/src/net/sf/openrocket/optimization/general/multidim/MultidirectionalSearchOptimizer.java index 9f3572dd9..fd7456a6d 100644 --- a/core/src/net/sf/openrocket/optimization/general/multidim/MultidirectionalSearchOptimizer.java +++ b/core/src/net/sf/openrocket/optimization/general/multidim/MultidirectionalSearchOptimizer.java @@ -174,7 +174,7 @@ public class MultidirectionalSearchOptimizer implements FunctionOptimizer, Stati if (accept(coordinateSearch, currentValue)) { - log.debug("Coordinate search successful, reseting simplex"); + log.debug("Coordinate search successful, resetting simplex"); List toAbort = new LinkedList(simplex); simplex.clear(); simplex.add(current); diff --git a/core/src/net/sf/openrocket/preset/xml/MaterialDTO.java b/core/src/net/sf/openrocket/preset/xml/MaterialDTO.java index abcebda70..f7499ff9c 100644 --- a/core/src/net/sf/openrocket/preset/xml/MaterialDTO.java +++ b/core/src/net/sf/openrocket/preset/xml/MaterialDTO.java @@ -86,7 +86,7 @@ public class MaterialDTO { /** * Special directive to the JAXB system. After the object is parsed from xml, * we replace the '2' with Chars.SQUARED, and '3' with Chars.CUBED. Just the - * opposite transformation as doen in beforeMarshal. + * opposite transformation as done in beforeMarshal. * @param unmarshaller * @param parent */ diff --git a/core/src/net/sf/openrocket/rocketcomponent/BoxBounded.java b/core/src/net/sf/openrocket/rocketcomponent/BoxBounded.java index 700d2c9d4..328d5c7f1 100644 --- a/core/src/net/sf/openrocket/rocketcomponent/BoxBounded.java +++ b/core/src/net/sf/openrocket/rocketcomponent/BoxBounded.java @@ -6,7 +6,7 @@ public interface BoxBounded { /** * Get a bounding box for a single instance of this component, from its own reference point. - * This is expected to be compbined with a InstanceContext for bounds in the global / rocket frame. + * This is expected to be combined with a InstanceContext for bounds in the global / rocket frame. * * @return BoundingBox from the instance's reference point. */ diff --git a/core/src/net/sf/openrocket/rocketcomponent/CenteringRing.java b/core/src/net/sf/openrocket/rocketcomponent/CenteringRing.java index cc24ce7e5..f9ff35916 100644 --- a/core/src/net/sf/openrocket/rocketcomponent/CenteringRing.java +++ b/core/src/net/sf/openrocket/rocketcomponent/CenteringRing.java @@ -25,7 +25,7 @@ public class CenteringRing extends RadiusRingComponent { // Implement sibling inner radius automation if (isInnerRadiusAutomatic()) { innerRadius = 0; - // Component can be parentless if disattached from rocket + // Component can be parentless if detached from rocket if (this.getParent() != null) { for (RocketComponent sibling : this.getParent().getChildren()) { /* diff --git a/core/src/net/sf/openrocket/rocketcomponent/FlightConfiguration.java b/core/src/net/sf/openrocket/rocketcomponent/FlightConfiguration.java index e1fbfef99..f7a3e2d02 100644 --- a/core/src/net/sf/openrocket/rocketcomponent/FlightConfiguration.java +++ b/core/src/net/sf/openrocket/rocketcomponent/FlightConfiguration.java @@ -263,7 +263,7 @@ public class FlightConfiguration implements FlightConfigurableParameter getActiveComponents() { Queue toProcess = new ArrayDeque(this.getActiveStages()); diff --git a/core/src/net/sf/openrocket/rocketcomponent/MotorMount.java b/core/src/net/sf/openrocket/rocketcomponent/MotorMount.java index 4c6b2f112..bc0641bfe 100644 --- a/core/src/net/sf/openrocket/rocketcomponent/MotorMount.java +++ b/core/src/net/sf/openrocket/rocketcomponent/MotorMount.java @@ -49,7 +49,7 @@ public interface MotorMount extends ChangeSource, FlightConfigurableComponent { public MotorConfiguration getDefaultMotorConfig(); /** - * Default implementatino supplied by RocketComponent (returns 1); + * Default implementation supplied by RocketComponent (returns 1); * * @return number of times this component is instanced */ diff --git a/core/src/net/sf/openrocket/rocketcomponent/RocketComponent.java b/core/src/net/sf/openrocket/rocketcomponent/RocketComponent.java index 6b937c589..4391770c0 100644 --- a/core/src/net/sf/openrocket/rocketcomponent/RocketComponent.java +++ b/core/src/net/sf/openrocket/rocketcomponent/RocketComponent.java @@ -97,11 +97,11 @@ public abstract class RocketComponent implements ChangeSource, Cloneable, Iterab // Override mass/CG private double overrideMass = 0; - private boolean massOverriden = false; + private boolean massOverridden = false; private double overrideCGX = 0; - private boolean cgOverriden = false; + private boolean cgOverridden = false; private double overrideCD = 0; - private boolean cdOverriden = false; + private boolean cdOverridden = false; private boolean overrideSubcomponents = false; @@ -234,7 +234,7 @@ public abstract class RocketComponent implements ChangeSource, Cloneable, Iterab * Return a collection of bounding coordinates. The coordinates must be such that * the component is fully enclosed in their convex hull. * - * Note: this function gets the bounds only for this component. Subchildren must be called individually. + * Note: this function gets the bounds only for this component. Sub-children must be called individually. * * @return a collection of coordinates that bound the component. */ @@ -521,7 +521,7 @@ public abstract class RocketComponent implements ChangeSource, Cloneable, Iterab return; checkState(); overrideMass = Math.max(m, 0); - if (massOverriden) + if (massOverridden) fireComponentChangeEvent(ComponentChangeEvent.MASS_CHANGE); } @@ -533,7 +533,7 @@ public abstract class RocketComponent implements ChangeSource, Cloneable, Iterab */ public final boolean isMassOverridden() { mutex.verify(); - return massOverriden; + return massOverridden; } /** @@ -542,11 +542,11 @@ public abstract class RocketComponent implements ChangeSource, Cloneable, Iterab * @param o whether the mass is overridden */ public final void setMassOverridden(boolean o) { - if (massOverriden == o) { + if (massOverridden == o) { return; } checkState(); - massOverriden = o; + massOverridden = o; fireComponentChangeEvent(ComponentChangeEvent.MASS_CHANGE); } @@ -597,7 +597,7 @@ public abstract class RocketComponent implements ChangeSource, Cloneable, Iterab */ public final boolean isCGOverridden() { mutex.verify(); - return cgOverriden; + return cgOverridden; } /** @@ -606,17 +606,17 @@ public abstract class RocketComponent implements ChangeSource, Cloneable, Iterab * @param o whether the CG is overridden */ public final void setCGOverridden(boolean o) { - if (cgOverriden == o) { + if (cgOverridden == o) { return; } checkState(); - cgOverriden = o; + cgOverridden = o; fireComponentChangeEvent(ComponentChangeEvent.MASS_CHANGE); } - /** Return the current override CD. The CD is not neccesarily overriden. + /** Return the current override CD. The CD is not necessarily overridden. * * @return the override CG. */ @@ -644,27 +644,27 @@ public abstract class RocketComponent implements ChangeSource, Cloneable, Iterab /** - * Return whether the CD is currently overriden. + * Return whether the CD is currently overridden. * * @return whether the CD is overridden */ public final boolean isCDOverridden() { mutex.verify(); - return cdOverriden; + return cdOverridden; } /** - * Set whether the CD is currently overriden. + * Set whether the CD is currently overridden. * - * @param o whether the CD is overriden + * @param o whether the CD is overridden */ public final void setCDOverridden(boolean o) { - if(cdOverriden == o) { + if(cdOverridden == o) { return; } checkState(); - cdOverriden = o; + cdOverridden = o; fireComponentChangeEvent(ComponentChangeEvent.MASS_CHANGE); } @@ -1283,7 +1283,7 @@ public abstract class RocketComponent implements ChangeSource, Cloneable, Iterab */ public final double getMass() { mutex.verify(); - if (massOverriden) + if (massOverridden) return overrideMass; return getComponentMass(); } @@ -1311,10 +1311,10 @@ public abstract class RocketComponent implements ChangeSource, Cloneable, Iterab */ public final Coordinate getCG() { checkState(); - if (cgOverriden) + if (cgOverridden) return getOverrideCG().setWeight(getMass()); - if (massOverriden) + if (massOverridden) return getComponentCG().setWeight(getMass()); return getComponentCG(); @@ -2016,9 +2016,9 @@ public abstract class RocketComponent implements ChangeSource, Cloneable, Iterab this.color = src.color; this.lineStyle = src.lineStyle; this.overrideMass = src.overrideMass; - this.massOverriden = src.massOverriden; + this.massOverridden = src.massOverridden; this.overrideCGX = src.overrideCGX; - this.cgOverriden = src.cgOverriden; + this.cgOverridden = src.cgOverridden; this.overrideSubcomponents = src.overrideSubcomponents; this.name = src.name; this.comment = src.comment; diff --git a/core/src/net/sf/openrocket/rocketcomponent/Transition.java b/core/src/net/sf/openrocket/rocketcomponent/Transition.java index 422561119..85855c075 100644 --- a/core/src/net/sf/openrocket/rocketcomponent/Transition.java +++ b/core/src/net/sf/openrocket/rocketcomponent/Transition.java @@ -25,7 +25,7 @@ public class Transition extends SymmetricComponent implements InsideColorCompone private Shape type; private double shapeParameter; - private boolean clipped; // Not to be read - use isClipped(), which may be overriden + private boolean clipped; // Not to be read - use isClipped(), which may be overridden private double foreRadius, aftRadius; private boolean autoForeRadius, autoAftRadius2; // Whether the start radius is automatic diff --git a/core/src/net/sf/openrocket/rocketcomponent/TubeFinSet.java b/core/src/net/sf/openrocket/rocketcomponent/TubeFinSet.java index 1dcc33dd2..205c48555 100644 --- a/core/src/net/sf/openrocket/rocketcomponent/TubeFinSet.java +++ b/core/src/net/sf/openrocket/rocketcomponent/TubeFinSet.java @@ -264,7 +264,7 @@ public class TubeFinSet extends ExternalComponent implements AxialPositionable, @Override public double getLongitudinalUnitInertia() { - // Logitudinal Unit Inertia for a single tube fin. + // Longitudinal Unit Inertia for a single tube fin. // 1/12 * (3 * (r1^2 + r2^2) + h^2) final double inertia = (3 * (MathUtil.pow2(getOuterRadius()) + MathUtil.pow2(getInnerRadius())) + MathUtil.pow2(getLength())) / 12; if (fins == 1) { diff --git a/core/src/net/sf/openrocket/rocketvisitors/DepthFirstRecusiveVisitor.java b/core/src/net/sf/openrocket/rocketvisitors/DepthFirstRecursiveVisitor.java similarity index 82% rename from core/src/net/sf/openrocket/rocketvisitors/DepthFirstRecusiveVisitor.java rename to core/src/net/sf/openrocket/rocketvisitors/DepthFirstRecursiveVisitor.java index 29a0f6e51..c7cf56c68 100644 --- a/core/src/net/sf/openrocket/rocketvisitors/DepthFirstRecusiveVisitor.java +++ b/core/src/net/sf/openrocket/rocketvisitors/DepthFirstRecursiveVisitor.java @@ -3,7 +3,7 @@ package net.sf.openrocket.rocketvisitors; import net.sf.openrocket.rocketcomponent.RocketComponent; import net.sf.openrocket.rocketcomponent.RocketComponentVisitor; -public abstract class DepthFirstRecusiveVisitor implements RocketComponentVisitor { +public abstract class DepthFirstRecursiveVisitor implements RocketComponentVisitor { @Override public final void visit(RocketComponent visitable) { diff --git a/core/src/net/sf/openrocket/rocketvisitors/ListComponents.java b/core/src/net/sf/openrocket/rocketvisitors/ListComponents.java index 8a6f8f96b..4984a4cca 100644 --- a/core/src/net/sf/openrocket/rocketvisitors/ListComponents.java +++ b/core/src/net/sf/openrocket/rocketvisitors/ListComponents.java @@ -5,7 +5,7 @@ import java.util.List; import net.sf.openrocket.rocketcomponent.RocketComponent; -public class ListComponents extends DepthFirstRecusiveVisitor> { +public class ListComponents extends DepthFirstRecursiveVisitor> { private final Class componentClazz; protected List components = new ArrayList(); diff --git a/core/src/net/sf/openrocket/simulation/SimulationOptions.java b/core/src/net/sf/openrocket/simulation/SimulationOptions.java index f22015e76..f19815e85 100644 --- a/core/src/net/sf/openrocket/simulation/SimulationOptions.java +++ b/core/src/net/sf/openrocket/simulation/SimulationOptions.java @@ -59,7 +59,7 @@ public class SimulationOptions implements ChangeSource, Cloneable { private double windAverage = preferences.getDouble(Preferences.WIND_AVERAGE, 2.0); - private double windTurbulence = preferences.getDouble(Preferences.WIND_TURBULANCE, 0.1); + private double windTurbulence = preferences.getDouble(Preferences.WIND_TURBULENCE, 0.1); /* * SimulationOptions maintains the launch site parameters as separate double values, diff --git a/core/src/net/sf/openrocket/simulation/listeners/example/StopSimulationListener.java b/core/src/net/sf/openrocket/simulation/listeners/example/StopSimulationListener.java index 1dd744367..e179d2da9 100644 --- a/core/src/net/sf/openrocket/simulation/listeners/example/StopSimulationListener.java +++ b/core/src/net/sf/openrocket/simulation/listeners/example/StopSimulationListener.java @@ -7,7 +7,7 @@ import net.sf.openrocket.simulation.listeners.AbstractSimulationListener; /** * A simulation listener that stops the simulation after a specified number of steps or - * after a specified abount of simulation time. + * after a specified amount of simulation time. * * @author Sampo Niskanen */ diff --git a/core/src/net/sf/openrocket/startup/Preferences.java b/core/src/net/sf/openrocket/startup/Preferences.java index 3a9504858..e4a7aab27 100644 --- a/core/src/net/sf/openrocket/startup/Preferences.java +++ b/core/src/net/sf/openrocket/startup/Preferences.java @@ -83,7 +83,7 @@ public abstract class Preferences implements ChangeSource { public static final String LAUNCH_ROD_DIRECTION = "LaunchRodDirection"; public static final String WIND_DIRECTION = "WindDirection"; public static final String WIND_AVERAGE = "WindAverage"; - public static final String WIND_TURBULANCE = "WindTurbulence"; + public static final String WIND_TURBULENCE = "WindTurbulence"; public static final String LAUNCH_ALTITUDE = "LaunchAltitude"; public static final String LAUNCH_LATITUDE = "LaunchLatitude"; public static final String LAUNCH_LONGITUDE = "LaunchLongitude"; @@ -188,15 +188,15 @@ public abstract class Preferences implements ChangeSource { } public final double getWindTurbulenceIntensity() { - return Application.getPreferences().getChoice(Preferences.WIND_TURBULANCE, 0.9, 0.1); + return Application.getPreferences().getChoice(Preferences.WIND_TURBULENCE, 0.9, 0.1); } public final void setWindTurbulenceIntensity(double wti) { - double oldWTI = Application.getPreferences().getChoice(Preferences.WIND_TURBULANCE, 0.9, 0.3); + double oldWTI = Application.getPreferences().getChoice(Preferences.WIND_TURBULENCE, 0.9, 0.3); if (MathUtil.equals(oldWTI, wti)) return; - this.putDouble(Preferences.WIND_TURBULANCE, wti); + this.putDouble(Preferences.WIND_TURBULENCE, wti); fireChangeEvent(); } @@ -255,7 +255,7 @@ public abstract class Preferences implements ChangeSource { public double getWindSpeedDeviation() { - return this.getDouble(WIND_AVERAGE, 2) * this.getDouble(WIND_TURBULANCE, .1); + return this.getDouble(WIND_AVERAGE, 2) * this.getDouble(WIND_TURBULENCE, .1); } public void setWindSpeedDeviation(double windDeviation) { diff --git a/core/src/net/sf/openrocket/util/ListenerList.java b/core/src/net/sf/openrocket/util/ListenerList.java index cd726c6ed..266ff2539 100644 --- a/core/src/net/sf/openrocket/util/ListenerList.java +++ b/core/src/net/sf/openrocket/util/ListenerList.java @@ -27,7 +27,7 @@ public class ListenerList implements Invalidatable, Iterable { /** - * Sole contructor. + * Sole constructor. */ public ListenerList() { this.instantiationLocation = new Throwable(); @@ -73,7 +73,7 @@ public class ListenerList implements Invalidatable, Iterable { return true; } } - log.info("Attempting to remove non-existant listener " + listener); + log.info("Attempting to remove non-existent listener " + listener); return false; } diff --git a/core/src/net/sf/openrocket/util/SafetyMutex.java b/core/src/net/sf/openrocket/util/SafetyMutex.java index f391de1e9..869e4a5d2 100644 --- a/core/src/net/sf/openrocket/util/SafetyMutex.java +++ b/core/src/net/sf/openrocket/util/SafetyMutex.java @@ -162,7 +162,7 @@ public abstract class SafetyMutex { // Check that the mutex is locked by the current thread if (lockingThread != Thread.currentThread()) { - error("Mutex is being unlocked from differerent thread than where it was locked", false); + error("Mutex is being unlocked from different thread than where it was locked", false); return false; } diff --git a/core/src/net/sf/openrocket/util/Transformation.java b/core/src/net/sf/openrocket/util/Transformation.java index b40d9041c..baf167bbd 100644 --- a/core/src/net/sf/openrocket/util/Transformation.java +++ b/core/src/net/sf/openrocket/util/Transformation.java @@ -167,7 +167,7 @@ public class Transformation implements java.io.Serializable { } /** - * Applies the given transformation before this tranformation. The resulting + * Applies the given transformation before this transformation. The resulting * transformation result.transform(c) will equal this.transform(other.transform(c)). * * @param other Transformation to apply diff --git a/core/test/net/sf/openrocket/preset/TransitionComponentTests.java b/core/test/net/sf/openrocket/preset/TransitionComponentTests.java index 9826613cd..7f2802083 100644 --- a/core/test/net/sf/openrocket/preset/TransitionComponentTests.java +++ b/core/test/net/sf/openrocket/preset/TransitionComponentTests.java @@ -152,7 +152,7 @@ public class TransitionComponentTests extends BaseTestCase { } @Test - public void changeAftSholderLengthLeavesPreset() { + public void changeAftShoulderLengthLeavesPreset() { Transition tr = new Transition(); tr.loadPreset(preset); diff --git a/core/test/net/sf/openrocket/unit/FractionalUnitTest.java b/core/test/net/sf/openrocket/unit/FractionalUnitTest.java index 141733fd5..554fd3aff 100644 --- a/core/test/net/sf/openrocket/unit/FractionalUnitTest.java +++ b/core/test/net/sf/openrocket/unit/FractionalUnitTest.java @@ -149,7 +149,7 @@ public class FractionalUnitTest { assertEquals("-\u00B9\u2044\u2084", testUnit.toString(-.225)); assertEquals("-\u00B9\u2044\u2084", testUnit.toString(-.25)); assertEquals("-\u00B9\u2044\u2084", testUnit.toString(-.274)); - //assertEquals("-1/4", testUnit.toString(-.275)); // this has roundoff error which pushes it over epsilon + //assertEquals("-1/4", testUnit.toString(-.275)); // this has round-off error which pushes it over epsilon assertEquals("0", testUnit.toString(-0.024)); assertEquals("0", testUnit.toString(0)); @@ -253,7 +253,7 @@ public class FractionalUnitTest { assertEquals("7 \u2077\u2044\u2088", inchUnit.toString(length)); - // had problems with roundoff in decrement. + // had problems with round-off in decrement. double v = inchUnit.toUnit(length); for (int i = 0; i < 15; i++) { diff --git a/core/test/net/sf/openrocket/util/GeodeticComputationStrategyTest.java b/core/test/net/sf/openrocket/util/GeodeticComputationStrategyTest.java index 9dfd4e468..44aedfc3c 100644 --- a/core/test/net/sf/openrocket/util/GeodeticComputationStrategyTest.java +++ b/core/test/net/sf/openrocket/util/GeodeticComputationStrategyTest.java @@ -8,7 +8,7 @@ import org.junit.Test; public class GeodeticComputationStrategyTest { @Test - public void testSpericalAddCoordinate() { + public void testSphericalAddCoordinate() { double arcmin = (1.0 / 60.0); double arcsec = (1.0 / (60.0 * 60.0)); @@ -145,7 +145,7 @@ public class GeodeticComputationStrategyTest { @Test - public void testSpericalGetCoriolisAcceleration() { + public void testSphericalGetCoriolisAcceleration() { // For positive latitude and rotational velocity, a movement due east results in an acceleration due south Coordinate velocity = new Coordinate(-1000, 0, 0); diff --git a/swing/src/net/sf/openrocket/gui/adaptors/ParameterSetModel.java b/swing/src/net/sf/openrocket/gui/adaptors/ParameterSetModel.java index d417b853c..593a78e67 100644 --- a/swing/src/net/sf/openrocket/gui/adaptors/ParameterSetModel.java +++ b/swing/src/net/sf/openrocket/gui/adaptors/ParameterSetModel.java @@ -67,7 +67,7 @@ public class ParameterSetModel> impleme this.selected = item; return; }else{ - throw new IllegalArgumentException("attempted to set selected item (oftype "+item.getClass().getSimpleName() + throw new IllegalArgumentException("attempted to set selected item (of type "+item.getClass().getSimpleName() +") when this generic contains a type: "+this.selected.getClass().getSimpleName()); } } diff --git a/swing/src/net/sf/openrocket/gui/dialogs/preset/XTableColumnModel.java b/swing/src/net/sf/openrocket/gui/dialogs/preset/XTableColumnModel.java index ac05c7894..6155fe091 100644 --- a/swing/src/net/sf/openrocket/gui/dialogs/preset/XTableColumnModel.java +++ b/swing/src/net/sf/openrocket/gui/dialogs/preset/XTableColumnModel.java @@ -99,7 +99,7 @@ public class XTableColumnModel extends DefaultTableColumnModel { return null; } - /** Checks wether the specified column is currently visible. + /** Checks whether the specified column is currently visible. * @param aColumn column to check * @return visibility of specified column (false if there is no such column at all. [It's not visible, right?]) */ @@ -107,7 +107,7 @@ public class XTableColumnModel extends DefaultTableColumnModel { return (tableColumns.indexOf(aColumn) >= 0); } - /** Append column to the right of exisiting columns. + /** Append column to the right of existing columns. * Posts columnAdded event. * @param column The column to be added * @see #removeColumn diff --git a/swing/src/net/sf/openrocket/gui/figure3d/RocketFigure3d.java b/swing/src/net/sf/openrocket/gui/figure3d/RocketFigure3d.java index bdc286829..c2557f914 100644 --- a/swing/src/net/sf/openrocket/gui/figure3d/RocketFigure3d.java +++ b/swing/src/net/sf/openrocket/gui/figure3d/RocketFigure3d.java @@ -102,7 +102,7 @@ public class RocketFigure3d extends JPanel implements GLEventListener { this.rkt = document.getRocket(); this.setLayout(new BorderLayout()); - //Only initizlize GL if 3d is enabled. + //Only initialize GL if 3d is enabled. if (is3dEnabled()) { //Fixes a linux / X bug: Splash must be closed before GL Init SplashScreen splash = Splash.getSplashScreen(); diff --git a/swing/src/net/sf/openrocket/gui/main/SaveAsFileChooser.java b/swing/src/net/sf/openrocket/gui/main/SaveAsFileChooser.java index 36d84aa5d..534821333 100644 --- a/swing/src/net/sf/openrocket/gui/main/SaveAsFileChooser.java +++ b/swing/src/net/sf/openrocket/gui/main/SaveAsFileChooser.java @@ -54,10 +54,10 @@ public class SaveAsFileChooser extends JFileChooser { break; } - final RememberFilenamePropertyListener listner = new RememberFilenamePropertyListener(); - this.addPropertyChangeListener(JFileChooser.FILE_FILTER_CHANGED_PROPERTY, listner); - this.addPropertyChangeListener(JFileChooser.SELECTED_FILE_CHANGED_PROPERTY, listner); - this.addPropertyChangeListener(JFileChooser.SELECTED_FILES_CHANGED_PROPERTY, listner); + final RememberFilenamePropertyListener listener = new RememberFilenamePropertyListener(); + this.addPropertyChangeListener(JFileChooser.FILE_FILTER_CHANGED_PROPERTY, listener); + this.addPropertyChangeListener(JFileChooser.SELECTED_FILE_CHANGED_PROPERTY, listener); + this.addPropertyChangeListener(JFileChooser.SELECTED_FILES_CHANGED_PROPERTY, listener); this.setCurrentDirectory(((SwingPreferences) Application.getPreferences()).getDefaultDirectory()); diff --git a/swing/src/net/sf/openrocket/gui/preset/ButtonColumn.java b/swing/src/net/sf/openrocket/gui/preset/ButtonColumn.java index 98738980d..00437a758 100644 --- a/swing/src/net/sf/openrocket/gui/preset/ButtonColumn.java +++ b/swing/src/net/sf/openrocket/gui/preset/ButtonColumn.java @@ -27,7 +27,7 @@ import net.sf.openrocket.gui.widgets.SelectColorButton; * the button. * * The button can be invoked by a mouse click or by pressing the space bar - * when the cell has focus. Optionaly a mnemonic can be set to invoke the + * when the cell has focus. Optionally a mnemonic can be set to invoke the * button. When the button is invoked the provided Action is invoked. The * source of the Action will be the table. The action command will contain * the model row number of the button that was clicked. diff --git a/swing/src/net/sf/openrocket/gui/rocketfigure/FinSetShapes.java b/swing/src/net/sf/openrocket/gui/rocketfigure/FinSetShapes.java index 29d98a266..2a95df58e 100644 --- a/swing/src/net/sf/openrocket/gui/rocketfigure/FinSetShapes.java +++ b/swing/src/net/sf/openrocket/gui/rocketfigure/FinSetShapes.java @@ -20,7 +20,7 @@ public class FinSetShapes extends RocketComponentShape { // this supplied transformation includes: // - baseRotationTransformation - // - mount-radius transformtion + // - mount-radius transformation // - component-center offset transformation // - component-instance offset transformation diff --git a/swing/src/net/sf/openrocket/gui/scalefigure/FinPointFigure.java b/swing/src/net/sf/openrocket/gui/scalefigure/FinPointFigure.java index a2de08848..d6a06bd2f 100644 --- a/swing/src/net/sf/openrocket/gui/scalefigure/FinPointFigure.java +++ b/swing/src/net/sf/openrocket/gui/scalefigure/FinPointFigure.java @@ -161,7 +161,7 @@ public class FinPointFigure extends AbstractScaleFigure { } } - // NOTE: This function drawns relative to the reference point of the BODY component + // NOTE: This function draws relative to the reference point of the BODY component // In other words: 0,0 == the front, foreRadius of the body component private void paintBodyTransition( Graphics2D g2){ diff --git a/swing/src/net/sf/openrocket/gui/widgets/MultiSlider.java b/swing/src/net/sf/openrocket/gui/widgets/MultiSlider.java index e5449da21..c29fe7acc 100644 --- a/swing/src/net/sf/openrocket/gui/widgets/MultiSlider.java +++ b/swing/src/net/sf/openrocket/gui/widgets/MultiSlider.java @@ -5,7 +5,7 @@ package net.sf.openrocket.gui.widgets; * Java source file for the class MultiSlider * * Copyright (c), 1999 - 2002, Masahiro Takatsuka and GeoVISTA Center - * All Rights Researved. + * All Rights Reserved. * * Original Author: Masahiro Takatsuka * $Author: eytanadar $ @@ -37,7 +37,7 @@ import javax.swing.plaf.SliderUI; Implementation of class MultiSlider ====================================================================*/ /*** - * A component that lets the user graphically select values by slding + * A component that lets the user graphically select values by sliding * multiple thumbs within a bounded interval. MultiSlider inherits all * fields and methods from javax.swing.JSlider. *

@@ -70,7 +70,7 @@ public class MultiSlider extends JSlider { /*** * Creates a slider with the specified orientation and the - * specified mimimum, maximum, and initial values. + * specified minimum, maximum, and initial values. * * @exception IllegalArgumentException if orientation is not one of VERTICAL, HORIZONTAL * @@ -88,7 +88,7 @@ public class MultiSlider extends JSlider { /*** * Creates a slider with the specified orientation and the - * specified mimimum, maximum, and the number of thumbs. + * specified minimum, maximum, and the number of thumbs. * * @exception IllegalArgumentException if orientation is not one of VERTICAL, HORIZONTAL * @@ -105,7 +105,7 @@ public class MultiSlider extends JSlider { /*** * Creates a horizontal slider with the range 0 to 100 and - * an intitial value of 50. + * an initial value of 50. */ public MultiSlider() { this(HORIZONTAL, 0, 100); @@ -114,7 +114,7 @@ public class MultiSlider extends JSlider { /*** * Creates a slider using the specified orientation with the - * range 0 to 100 and an intitial value of 50. + * range 0 to 100 and an initial value of 50. */ public MultiSlider(int orientation) { this(orientation, 0, 100); @@ -123,7 +123,7 @@ public class MultiSlider extends JSlider { /*** * Creates a horizontal slider using the specified min and max - * with an intitial value of 50. + * with an initial value of 50. */ public MultiSlider(int min, int max) { this(HORIZONTAL, min, max); diff --git a/swing/src/net/sf/openrocket/gui/widgets/MultiSliderUI.java b/swing/src/net/sf/openrocket/gui/widgets/MultiSliderUI.java index 5bbfa31d4..c428b9e8a 100644 --- a/swing/src/net/sf/openrocket/gui/widgets/MultiSliderUI.java +++ b/swing/src/net/sf/openrocket/gui/widgets/MultiSliderUI.java @@ -5,7 +5,7 @@ package net.sf.openrocket.gui.widgets; * Java source file for the class MultiSliderUI * * Copyright (c), 1999 - 2002, Masahiro Takatsuka and GeoVISTA Center - * All Rights Researved. + * All Rights Reserved. * * Original Author: Masahiro Takatsuka * $Author: eytanadar $ diff --git a/swing/src/net/sf/openrocket/logging/LoggingSystemSetup.java b/swing/src/net/sf/openrocket/logging/LoggingSystemSetup.java index 774660803..76bbb9dc5 100644 --- a/swing/src/net/sf/openrocket/logging/LoggingSystemSetup.java +++ b/swing/src/net/sf/openrocket/logging/LoggingSystemSetup.java @@ -55,14 +55,14 @@ public class LoggingSystemSetup { */ public static DelegatorLogger getInstance() { Logger logger = (Logger) LoggerFactory.getLogger(Logger.ROOT_LOGGER_NAME); - LogbackBufferLoggerAdaptor adapater = (LogbackBufferLoggerAdaptor) logger.getAppender("buffer"); - return adapater.getLogHelper(); + LogbackBufferLoggerAdaptor adaptor = (LogbackBufferLoggerAdaptor) logger.getAppender("buffer"); + return adaptor.getLogHelper(); } public static LogLevelBufferLogger getBufferLogger() { Logger logger = (Logger) LoggerFactory.getLogger(Logger.ROOT_LOGGER_NAME); - LogbackBufferLoggerAdaptor adapater = (LogbackBufferLoggerAdaptor) logger.getAppender("buffer"); - return adapater.getLogBuffer(); + LogbackBufferLoggerAdaptor adaptor = (LogbackBufferLoggerAdaptor) logger.getAppender("buffer"); + return adaptor.getLogBuffer(); } } diff --git a/swing/src/net/sf/openrocket/logging/PrintStreamToSLF4J.java b/swing/src/net/sf/openrocket/logging/PrintStreamToSLF4J.java index e44d06bb4..583bf5f26 100644 --- a/swing/src/net/sf/openrocket/logging/PrintStreamToSLF4J.java +++ b/swing/src/net/sf/openrocket/logging/PrintStreamToSLF4J.java @@ -10,7 +10,7 @@ import org.slf4j.LoggerFactory; public class PrintStreamToSLF4J { - public static PrintStream getPrintStream(String category, PrintStream orignal) { + public static PrintStream getPrintStream(String category, PrintStream original) { final Logger logger = LoggerFactory.getLogger(category); diff --git a/swing/src/net/sf/openrocket/startup/OpenRocket.java b/swing/src/net/sf/openrocket/startup/OpenRocket.java index dca1b33dc..d2227e153 100644 --- a/swing/src/net/sf/openrocket/startup/OpenRocket.java +++ b/swing/src/net/sf/openrocket/startup/OpenRocket.java @@ -28,7 +28,7 @@ public class OpenRocket { private static final String STARTUP_CLASS = "net.sf.openrocket.startup.SwingStartup"; public static void main(String[] args) { - // This property works around some fundimental bugs in TimSort in the java library which has had known issues + // This property works around some fundamental bugs in TimSort in the java library which has had known issues // since it was introduced in JDK 1.7. In OpenRocket it manifests when you sort the motors in the motor chooser dialog // by designation. System.setProperty("java.util.Arrays.useLegacyMergeSort","true"); diff --git a/swing/src/net/sf/openrocket/startup/providers/TranslatorProvider.java b/swing/src/net/sf/openrocket/startup/providers/TranslatorProvider.java index b10b83453..21081b01c 100644 --- a/swing/src/net/sf/openrocket/startup/providers/TranslatorProvider.java +++ b/swing/src/net/sf/openrocket/startup/providers/TranslatorProvider.java @@ -29,7 +29,7 @@ public class TranslatorProvider implements Provider { return oldTranslator; } - // Check for locale propery + // Check for locale property String langcode = System.getProperty("openrocket.locale"); if (langcode != null) {