Skip to content

Commit

Permalink
Merge pull request #989 from tdrwenski/fix-spelling
Browse files Browse the repository at this point in the history
[5.x] Fix spelling
  • Loading branch information
haileyajohnson authored Mar 25, 2022
2 parents c832cc3 + c2f8907 commit a742a9e
Showing 119 changed files with 245 additions and 245 deletions.
Original file line number Diff line number Diff line change
@@ -16,7 +16,7 @@ public class BitCounterCompressed implements BitCounter {

private final DataDescriptor dkey; // the field to count
private final int nrows; // number of (obs) in the compression
private final int bitOffset; // starting position of the compressed data, reletive to start of data section
private final int bitOffset; // starting position of the compressed data, relative to start of data section
private int dataWidth; // bitWidth of incremental values
private BitCounterCompressed[][] nested; // used if the dkey is a structure = nested[innerRows][dkey.subkeys.size]

Original file line number Diff line number Diff line change
@@ -116,7 +116,7 @@ public ArrayStructure readEntireMessage(Structure s, Message proto, Message m, R
* @param ama place data into here in order (may be null). iterators must be already set.
* @param m read this message
* @param raf from this file
* @param r which datasets, reletive to this message. null == all.
* @param r which datasets, relative to this message. null == all.
* @param f output bit count debugging info (may be null)
* @throws IOException on read error
*/
Original file line number Diff line number Diff line change
@@ -95,7 +95,7 @@ ArrayStructure readEntireMessage(Structure s, Message proto, Message m, RandomAc
* @param abb place data into here in order (may be null)
* @param m read this message
* @param raf from this file
* @param r which datasets, reletive to this message. null == all.
* @param r which datasets, relative to this message. null == all.
* @param addTime add the time coordinate
* @param f output bit count debugging info (may be null)
* @return number of datasets read
2 changes: 1 addition & 1 deletion bufr/src/main/sources/eumetsat/readme.txt
Original file line number Diff line number Diff line change
@@ -8,7 +8,7 @@ http://www.eumetsat.int/Home/Main/Access_to_Data/Meteosat_Meteorological_Product

the two table C are identical

table B and D (11) have additions, but no changes reletive to (10)
table B and D (11) have additions, but no changes relative to (10)

B:

Original file line number Diff line number Diff line change
@@ -81,7 +81,7 @@ public void pdsGenType() throws Exception {
assert v != null : ncfile.getLocation();
}

// this one has a forecast and error = must be seperate variables
// this one has a forecast and error = must be separate variables
filename = TestDir.cdmUnitTestDir + "formats/grib2/RTMA_CONUS_2p5km_20111225_0000.grib2";
logger.debug("{}", filename);
try (NetcdfFile ncfile = NetcdfFiles.open(filename, null)) {
Original file line number Diff line number Diff line change
@@ -653,7 +653,7 @@ Algorithm getAlgo() {
}

byte[] compress(GribData.Bean bean) throws IOException {
return GribData.compressScaled(bean); // LOOK could seperate from compression and try different ones
return GribData.compressScaled(bean); // LOOK could separate from compression and try different ones
}
}

4 changes: 2 additions & 2 deletions cdm/core/src/main/java/thredds/client/catalog/Access.java
Original file line number Diff line number Diff line change
@@ -63,7 +63,7 @@ public long getDataSize() {
} // optional

/**
* Get the standard URL, with resolution if the URL is reletive.
* Get the standard URL, with resolution if the URL is relative.
* catalog.resolveURI( getUnresolvedUrlName())
*
* @return URL string, or null if error.
@@ -95,7 +95,7 @@ public URI getStandardUri() {

/**
* Construct "unresolved" URL: service.getBase() + getUrlPath() + service.getSuffix().
* It is not resolved, so it may be a reletive URL.
* It is not resolved, so it may be a relative URL.
*
* @return unresolved Url as a String
*/
4 changes: 2 additions & 2 deletions cdm/core/src/main/java/thredds/client/catalog/Catalog.java
Original file line number Diff line number Diff line change
@@ -168,10 +168,10 @@ private void addAll(DatasetNode node, List<Dataset> all) {
}

/**
* Resolve reletive URIs, using the catalog's base URI. If the uriString is not reletive, then
* Resolve relative URIs, using the catalog's base URI. If the uriString is not relative, then
* no resolution is done. This also allows baseURI to be a file: scheme.
*
* @param uriString any url, reletive or absolute
* @param uriString any url, relative or absolute
* @return resolved url string, or null on error
* @throws java.net.URISyntaxException if uriString violates RFC 2396
*/
Original file line number Diff line number Diff line change
@@ -75,7 +75,7 @@ protected String translatePathToReletiveLocation(String dsPath, String configPat
if (!dsPath.startsWith(configPath))
return null;

// remove the matching part, the rest is the "reletive location"
// remove the matching part, the rest is the "relative location"
String dataDir = dsPath.substring(configPath.length());
if (dataDir.startsWith("/"))
dataDir = dataDir.substring(1);
4 changes: 2 additions & 2 deletions cdm/core/src/main/java/thredds/client/catalog/Service.java
Original file line number Diff line number Diff line change
@@ -78,9 +78,9 @@ public List<Property> getProperties() {
}

/**
* See if the service Base is reletive
* See if the service Base is relative
*
* @return true if the service Base is reletive
* @return true if the service Base is relative
*/
public boolean isRelativeBase() {
if (getType() == ServiceType.Compound)
Original file line number Diff line number Diff line change
@@ -88,7 +88,7 @@ public DatasetBuilder(DatasetBuilder parent, Dataset from) {
this.parent = parent;
this.name = from.getName();
for (Map.Entry<String, Object> entry : from.getFldIterator()) {
if (!entry.getKey().equals(Dataset.Datasets) && !entry.getKey().equals(Dataset.Access)) // set seperately
if (!entry.getKey().equals(Dataset.Datasets) && !entry.getKey().equals(Dataset.Access)) // set separately
this.flds.put(entry.getKey(), entry.getValue());
}
}
Original file line number Diff line number Diff line change
@@ -420,7 +420,7 @@ private String rangeString(ThreddsMetadata.GeospatialRange r) {
}

/**
* resolve reletive URLS against the catalog URL.
* resolve relative URLS against the catalog URL.
*
* @param ds use ds parent catalog, if it exists
* @param href URL to resolve
4 changes: 2 additions & 2 deletions cdm/core/src/main/java/ucar/ma2/Range.java
Original file line number Diff line number Diff line change
@@ -262,12 +262,12 @@ public boolean contains(int want) {
}

/**
* Create a new Range by composing a Range that is reletive to this Range.
* Create a new Range by composing a Range that is relative to this Range.
* Revised 2013/04/19 by Dennis Heimbigner to handle edge cases.
* See the commentary associated with the netcdf-c file dceconstraints.h,
* function dceslicecompose().
*
* @param r range reletive to base
* @param r range relative to base
* @return combined Range, may be EMPTY
* @throws InvalidRangeException elements must be nonnegative, 0 <= first <= last
*/
6 changes: 3 additions & 3 deletions cdm/core/src/main/java/ucar/ma2/Section.java
Original file line number Diff line number Diff line change
@@ -273,9 +273,9 @@ public Section compact() throws InvalidRangeException {


/**
* Create a new Section by composing with a Section that is reletive to this Section.
* Create a new Section by composing with a Section that is relative to this Section.
*
* @param want Section reletive to this one. If null, return this. If individual ranges are null, use corresponding
* @param want Section relative to this one. If null, return this. If individual ranges are null, use corresponding
* Range in this.
* @return new Section, composed
* @throws InvalidRangeException if want.getRank() not equal to this.getRank(), or invalid component Range
@@ -371,7 +371,7 @@ public Section union(Section other) throws InvalidRangeException {

/**
* Create a new Section by shifting each range by newOrigin.first()
* The result is then a reletive offset from the newOrigin.
* The result is then a relative offset from the newOrigin.
*
* @param newOrigin this becomes the origin of the result
* @return new Section, shifted
2 changes: 1 addition & 1 deletion cdm/core/src/main/java/ucar/nc2/Dimension.java
Original file line number Diff line number Diff line change
@@ -210,7 +210,7 @@ public String getShortName() {
/**
* If this is a NetCDF unlimited dimension. The length might increase between invocations,
* but it remains fixed for the lifetime of the NetcdfFile.
* If you modify the file in a seperate process, you must close and reopen the file.
* If you modify the file in a separate process, you must close and reopen the file.
*
* @return if its an "unlimited" Dimension
*/
26 changes: 13 additions & 13 deletions cdm/core/src/main/java/ucar/nc2/Group.java
Original file line number Diff line number Diff line change
@@ -1071,20 +1071,20 @@ public Optional<Group.Builder> findGroupLocal(String shortName) {
}

/**
* Find a subgroup of this Group, with the specified reletive name.
* Find a subgroup of this Group, with the specified relative name.
* An embedded "/" separates group names.
* Can have a leading "/" only if this is the root group.
*
* @param reletiveName eg "group/subgroup/wantGroup".
* @param relativeName eg "group/subgroup/wantGroup".
* @return Group or empty if not found.
*/
public Optional<Group.Builder> findGroupNested(String reletiveName) {
if (reletiveName == null || reletiveName.isEmpty()) {
public Optional<Group.Builder> findGroupNested(String relativeName) {
if (relativeName == null || relativeName.isEmpty()) {
return (this.getParentGroup() == null) ? Optional.of(this) : Optional.empty();
}

Group.Builder g = this;
StringTokenizer stoke = new StringTokenizer(reletiveName, "/");
StringTokenizer stoke = new StringTokenizer(relativeName, "/");
while (stoke.hasMoreTokens()) {
String groupName = NetcdfFiles.makeNameUnescaped(stoke.nextToken());
Optional<Group.Builder> sub = g.findGroupLocal(groupName);
@@ -1190,22 +1190,22 @@ public Optional<Variable.Builder<?>> findVariableLocal(String name) {
}

/**
* Find a Variable, with the specified reletive name. No structure members.
* Find a Variable, with the specified relative name. No structure members.
*
* @param reletiveName eg "group/subgroup/varname".
* @param relativeName eg "group/subgroup/varname".
*/
public Optional<Variable.Builder<?>> findVariableNested(String reletiveName) {
if (reletiveName == null || reletiveName.isEmpty()) {
public Optional<Variable.Builder<?>> findVariableNested(String relativeName) {
if (relativeName == null || relativeName.isEmpty()) {
return Optional.empty();
}

// break into groupNames and varName
Group.Builder group = this;
String varName = reletiveName;
int pos = reletiveName.lastIndexOf('/');
String varName = relativeName;
int pos = relativeName.lastIndexOf('/');
if (pos >= 0) {
String groupNames = reletiveName.substring(0, pos);
varName = reletiveName.substring(pos + 1);
String groupNames = relativeName.substring(0, pos);
varName = relativeName.substring(pos + 1);
group = findGroupNested(groupNames).orElse(null);
}

2 changes: 1 addition & 1 deletion cdm/core/src/main/java/ucar/nc2/Variable.java
Original file line number Diff line number Diff line change
@@ -1801,7 +1801,7 @@ public boolean isCoordinateVariable() {
protected int elementSize;

// TODO do we need these? breaks immutability
// TODO maybe caching read data shoul be seperate from "this is the source of the data".
// TODO maybe caching read data should be separate from "this is the source of the data".
protected Cache cache = new Cache(); // cache cannot be null
protected int sizeToCache = -1; // bytes

Original file line number Diff line number Diff line change
@@ -158,7 +158,7 @@ public static NetcdfDataset openDataset(DatasetUrl location, Set<Enhance> enhanc
* eg: NcmlReader.readNcml(new StringReader(ncml), location, null);
*
* @param reader the Reader containing the NcML document
* @param ncmlLocation the URL location string of the NcML document, used to resolve reletive path of the referenced
* @param ncmlLocation the URL location string of the NcML document, used to resolve relative path of the referenced
* dataset,
* or may be just a unique name for caching purposes.
* @param cancelTask allow user to cancel the task; may be null
Original file line number Diff line number Diff line change
@@ -101,7 +101,7 @@ public void augmentDataset(NetcdfDataset ds, CancelTask cancelTask) throws IOExc
}

// figure out the time coordinate for each data variable
// LOOK : always seperate; could try to discover if they are the same
// LOOK : always separate; could try to discover if they are the same
List<Variable> vars = ds.getVariables();
for (Variable ncvar : vars) {
// variables that are used but not displayable or have no data have DIM_0, also don't want history, since those
2 changes: 1 addition & 1 deletion cdm/core/src/main/java/ucar/nc2/dt/GridCoordSystem.java
Original file line number Diff line number Diff line change
@@ -40,7 +40,7 @@ public interface GridCoordSystem {
*/

/**
* The name of the Grid Coordinate System, consisting of the list of coordinate axes, seperated by blanks.
* The name of the Grid Coordinate System, consisting of the list of coordinate axes, separated by blanks.
*
* @return name of the Grid Coordinate System
*/
2 changes: 1 addition & 1 deletion cdm/core/src/main/java/ucar/nc2/ft/fmrc/FmrInv.java
Original file line number Diff line number Diff line change
@@ -130,7 +130,7 @@ public int compareTo(FmrInv fmr) {

/**
* A grid variable for an fmr (one run)
* A collection of GridDatasetInv.Grid, one for each seperate dataset. All have the same runDate.
* A collection of GridDatasetInv.Grid, one for each separate dataset. All have the same runDate.
* The time and vert coord of the GridVariable is the union of the GridDatasetInv.Grid time and vert coords.
*
* @author caron
4 changes: 2 additions & 2 deletions cdm/core/src/main/java/ucar/nc2/ft/fmrc/FmrcInv.java
Original file line number Diff line number Diff line change
@@ -168,8 +168,8 @@ public class FmrcInv {
}

// not really needed
private final TimeCoord tcOffAll; // all offsets in this collection, reletive to baseDate
private final TimeCoord tcIntAll; // all intervals in this collection, reletive to baseDate
private final TimeCoord tcOffAll; // all offsets in this collection, relative to baseDate
private final TimeCoord tcIntAll; // all intervals in this collection, relative to baseDate

// public for debugging
public List<FmrInv> getFmrList() {
Original file line number Diff line number Diff line change
@@ -289,7 +289,7 @@ private Grid makeGrid(String gridName) {
*/
public class Grid implements Comparable<Grid> {
final String name;
TimeCoord tc; // time coordinates reletive to getRunDate()
TimeCoord tc; // time coordinates relative to getRunDate()
EnsCoord ec; // optional
VertCoord vc; // optional

4 changes: 2 additions & 2 deletions cdm/core/src/main/java/ucar/nc2/ft/point/standard/Table.java
Original file line number Diff line number Diff line change
@@ -65,7 +65,7 @@ public static Table factory(NetcdfDataset ds, TableConfig config) {
case ArrayStructure: // given array of StructureData, stored in config.as
return new TableArrayStructure(ds, config);

case Construct: // construct the table from its children - theres no seperate station table, stn info is
case Construct: // construct the table from its children - theres no separate station table, stn info is
// duplicated in the obs structure.
return new TableConstruct(ds, config);

@@ -405,7 +405,7 @@ public String getName() {
///////////////////////////////////////////////////////

/**
* When theres no seperate station table, but info is duplicated in the obs structure.
* When theres no separate station table, but info is duplicated in the obs structure.
* Must have a ParentId child table
* No variables are added to cols.
* <p>
Original file line number Diff line number Diff line change
@@ -20,7 +20,7 @@
* 1) ConstantForecast: runtime (ind), timeOffset (dep), time (scalar)
* 1) Best: time (ind), runtime (dep)
*
* Grib: If theres a time offset, then there must be a runtime coordinate, and the time offset is reletive to that.
* Grib: If theres a time offset, then there must be a runtime coordinate, and the time offset is relative to that.
* LOOK only used by Grib
*/
@Immutable
Original file line number Diff line number Diff line change
@@ -367,7 +367,7 @@ protected Optional<CoverageCoordAxisBuilder> subsetBuilder(SubsetParams params)
// default is all
break;

// x,y get seperately subsetted
// x,y get separately subsetted
case GeoX:
case GeoY:
case Lat:
Original file line number Diff line number Diff line change
@@ -59,7 +59,7 @@ public Optional<TimeOffsetAxis> subsetFromTime(SubsetParams params, CalendarDate

assert (builder != null);

// all the offsets are reletive to rundate
// all the offsets are relative to rundate
builder.setReferenceDate(runDate);
return Optional.of(new TimeOffsetAxis(builder));
}
Original file line number Diff line number Diff line change
@@ -113,7 +113,7 @@ public void augmentDataset(CancelTask cancelTask) throws IOException {
}

// figure out the time coordinate for each data variable
// LOOK : always seperate; could try to discover if they are the same
// LOOK : always separate; could try to discover if they are the same
// Make copy because we will add new elements to it.
for (Variable.Builder<?> ncvar : ImmutableList.copyOf(rootGroup.vbuilders)) {
// variables that are used but not displayable or have no data have DIM_0, also don't want history, since those
Original file line number Diff line number Diff line change
@@ -795,7 +795,7 @@ protected void assignCoordinateTransforms() {
coords.findAxisByType(cs, AxisType.GeoZ).ifPresent(axis -> {
String units = axis.getUnits();
if ((units == null) || (units.trim().isEmpty())) {
// LOOK each cs might have seperate ct; but they might be identical....
// LOOK each cs might have separate ct; but they might be identical....
VerticalCTBuilder vctb = new WRFEtaTransformBuilder(coords, cs);
coords.addVerticalCTBuilder(vctb);
cs.addCoordinateTransformByName(vctb.getTransformName());
Original file line number Diff line number Diff line change
@@ -440,7 +440,7 @@ public LayoutBBTiled.DataChunk next() {
}

private class DataChunk implements LayoutBBTiled.DataChunk {
private int[] offset; // offset index of this chunk, reletive to entire array
private int[] offset; // offset index of this chunk, relative to entire array
private H4header.SpecialComp compress;
private ByteBuffer bb; // the data is placed into here

Original file line number Diff line number Diff line change
@@ -1059,7 +1059,7 @@ private Array readAttributeData(MessageAttribute matt, H5headerNew.Vinfo vinfo,
}
StructureMembers.MemberBuilder mb = builder.addMember(h5sm.name, null, null, dt, dim);

if (h5sm.mdt.endian >= 0) // apparently each member may have seperate byte order (!!!??)
if (h5sm.mdt.endian >= 0) // apparently each member may have separate byte order (!!!??)
mb.setDataObject(
h5sm.mdt.endian == RandomAccessFile.LITTLE_ENDIAN ? ByteOrder.LITTLE_ENDIAN : ByteOrder.BIG_ENDIAN);
mb.setDataParam(h5sm.offset); // offset since start of Structure
Original file line number Diff line number Diff line change
@@ -443,7 +443,7 @@ private boolean convertStructure(Structure s, StructureMembers sm) {
assert v2 != null;
H5headerNew.Vinfo vm = (H5headerNew.Vinfo) v2.getSPobject();

// apparently each member may have seperate byte order (!!!??)
// apparently each member may have separate byte order (!!!??)
if (vm.typeInfo.endian >= 0)
m.setDataObject(
vm.typeInfo.endian == RandomAccessFile.LITTLE_ENDIAN ? ByteOrder.LITTLE_ENDIAN : ByteOrder.BIG_ENDIAN);
Original file line number Diff line number Diff line change
@@ -2519,7 +2519,7 @@ class HeapIdentifier {
// the heap id is has already been read into a byte array at given pos
HeapIdentifier(ByteBuffer bb, int pos) {
bb.order(ByteOrder.LITTLE_ENDIAN); // header information is in le byte order
bb.position(pos); // reletive reading
bb.position(pos); // relative reading
nelems = bb.getInt();
heapAddress = header.isOffsetLong ? bb.getLong() : (long) bb.getInt();
index = bb.getInt();
Original file line number Diff line number Diff line change
@@ -41,7 +41,7 @@ public H5tiledLayout(H5headerNew.Vinfo vinfo, DataType dtype, Section wantSectio
assert vinfo.btree != null;

// we have to translate the want section into the same rank as the storageSize, in order to be able to call
// Section.intersect(). It appears that storageSize (actually msl.chunkSize) may have an extra dimension, reletive
// Section.intersect(). It appears that storageSize (actually msl.chunkSize) may have an extra dimension, relative
// to the Variable.
if ((dtype == DataType.CHAR) && (wantSection.getRank() < vinfo.storageSize.length)) {
this.want = Section.builder().appendRanges(wantSection.getRanges()).appendRange(1).build();
Loading

0 comments on commit a742a9e

Please sign in to comment.