Package hec.heclib.dss
Class HecDSSDataAttributes
java.lang.Object
hec.heclib.dss.HecDSSFileAccess
hec.heclib.dss.HecDssCatalog
hec.heclib.dss.HecDSSDataAttributes
- All Implemented Interfaces:
HecDssListener,Cloneable,EventListener
- Direct Known Subclasses:
HecDataManager
HecDSSDataAttributes contains various data utility methods and constants.
includes: data type and other constants, path utilities, factory methods for IO objects,
and time window methods.
-
Nested Class Summary
Nested classes/interfaces inherited from class hec.heclib.dss.HecDssCatalog
HecDssCatalog.WriteCatalogFileRunnable -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected HecTimeprotected intprotected HecTimeprotected intprotected intprotected intprotected static HecTimeprotected static HecTimeprotected intprotected booleanprotected DSSPathnameprotected HecTimeprotected intprotected booleanprotected intprotected int[]protected HecTimeprotected booleanprotected booleanprotected Stringprotected Stringstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intFields inherited from class hec.heclib.dss.HecDssCatalog
_catalogName, _forceNewCatalog, _listenerList, _observerThreads, _useCollectionGroups, crcValues, dataTypeEnd, dataTypeStart, endDates, lastWriteTimeFile, lastWriteTimeRecord, listIsCollection, listIsComplete, listIsSorted, maxNumberToRetrieve, pathnameAddresses, pathnameHash, pathnameList, pathnameWithWild, startDates, statusRead, statusWantedFields inherited from class hec.heclib.dss.HecDSSFileAccess
_defaultDirectory, _defaultDSSFileName, _fileData, _maxNumberReopensForError, _numberReopensForError, _severeErrorIndex, _severeErrorMessages, _severeErrorRaised, ABBREVIATED_CATALOG, CONDENSED_CATALOG, FULL_CATALOG, MESS_LEVEL_CRITICAL, MESS_LEVEL_GENERAL, MESS_LEVEL_INTERNAL_DIAG_1, MESS_LEVEL_INTERNAL_DIAG_2, MESS_LEVEL_NONE, MESS_LEVEL_TERSE, MESS_LEVEL_USER_DIAG, MESS_METHOD_ALIAS, MESS_METHOD_CATALOG, MESS_METHOD_CHECK, MESS_METHOD_COPY, MESS_METHOD_FILE_CHECK, MESS_METHOD_GENERAL, MESS_METHOD_GET, MESS_METHOD_GLOBAL, MESS_METHOD_JNI, MESS_METHOD_LOCKING, MESS_METHOD_OPEN, MESS_METHOD_PERM, MESS_METHOD_PUT, MESS_METHOD_READ, MESS_METHOD_TS_READ, MESS_METHOD_TS_WRITE, MESS_METHOD_UTILITY, MESS_METHOD_WRITE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaPart()bPart()static voidstatic intconvertDoubleUnits(double[] data, int number, int fromUnits, int toUnits) static intconvertUnits(double[] data, int number, int fromUnitSyst, int toUnitSyst, stringContainer units) cPart()createArrayObject(String pathname) createObject(String pathname) createPairedDataObject(String pathname) createTextObject(String pathname) createTimeSeriesObject(String pathname) static Stringstatic Stringstatic Stringstatic Stringstatic Stringstatic Stringbooleandirty()dPart()endTime()ePart()fPart()getLastWriteTime(String pathname) longlonggetLastWriteTimeMillis(String pathname) booleanisGridRecord(String pathname) Determines if record for the given pathname is represents a grid.booleanintpathname()static intpathnameDataType(String pathname) Tries to determine data type quickly from pathname only, without accessing the DSS file.byte[]byte[]readRawBytes(int[] internalHeader, int limitInternalHeader, int[] numberInternalHeader, int[] compressionHeader, int limitCompressionHeader, int[] numberCompressionHeader, int[] userHeader, int limitUserHeader, int[] numberUserHeader, int[] stat) intreadRawRecord(RawContainer rawContainer, boolean getLengthsOnly) short[]short[]readRawShorts(int[] internalHeader, int limitInternalHeader, int[] numberInternalHeader, int[] compressionHeader, int limitCompressionHeader, int[] numberCompressionHeader, int[] userHeader, int limitUserHeader, int[] numberUserHeader, int[] stat) booleanrecordExists(String pathname) intrecordsUpdated(long startTime, List<String> pathnames, List<Long> updateTimes, List<Integer> recordTypes) Retrieves infomation about record updated since the specified time.intintrecordType(String pathname) recordTypes(String[] pathnames) voidvoidvoidstatic voidsetDefaultAPart(String partName) static voidsetDefaultBPart(String partName) static voidsetDefaultCPart(String partName) static voidsetDefaultDPart(String partName) static intsetDefaultEPart(String partName) static voidsetDefaultFPart(String partName) intsetDefaultPathnameParts(String pathnameParts) voidsetDefaultTimeWindow(HecTime startTime, HecTime endTime) intsetDefaultTimeWindow(String userLine) voidintsetDSSFileName(String dssFileName, boolean fileMustExist) voidsetEndTime(HecTime endTime) intvoidvoidsetLocalUnitSystem(int localUnitSystem) intsetPathname(String path) intsetPathnameParts(String pathnameParts) voidsetStartTime(HecTime startTime) voidsetTimeWindow(HecTime startTime, HecTime endTime) intsetTimeWindow(String userLine) voidstatus()intwriteRawRecord(RawContainer rawContainer) Methods inherited from class hec.heclib.dss.HecDssCatalog
addHecDssListener, addHecDssListener, addHecDssListener, addHecDssListener, addHecDssListener, addHecDssListener, addHecDssListener, buildCondensedList, buildSortedCatalog, callCatalog, callCatalog, callCatalog, callCatalogOriginal, catalogFile, cleanCatalogPart, clearList, clone, compareCondensedPaths, createNewCatalog, expandPathname, fireHecDssEvent, getCatalog, getCatalog, getCatalog, getCatalogName, getCatalogSortAddresses, getCondensedCatalog, getCondensedCatalog, getEndDates, getEPartLoc, getMaximumPartLengths, getMaximumPartLengths, getPathnameList, getPathnameList, getPathnameList6, getPathnameList7, getPathnameListAndDates, getPathnameListType, getPathnames, getSortedPathnameList, getStartDates, getStatusRead, getUseCollectionGroups, hecDssEventPerformed, isCatalogValid, isPathnamePartsString, numberCatalogedRecords, pathNamePartsToRegex, processSearchParts, readCatalog, removeHecDssListener, searchDSSCatalog, searchDSSCatalog, searchDSSPaths, searchDSSPaths, setCatalogSortAddresses, setForceNewCatalog, setMaxNumberToRetrieve, setPathnameList, setPathnameList, setPathWithWildChars, setStatusWanted, setTypeWanted, setUseCollectionGroups, sort, sortCatalog, startObserverThread, whatChanged, whatChanged, whatChangedCompare, whatChangedSetStart, whatChangedSetStart, whatChangedSetStart, wildCharsToRegex, writeCatalogMethods inherited from class hec.heclib.dss.HecDSSFileAccess
allSevereErrorMessages, appendNameToDirectory, catchSevereErrors, checkAccessReset, checkAllPathnames, checkForError, checkForSevereError, checkForSevereError, checkForSevereFileError, checkLinks, checkPathnameBins, checkSystemError, cleanDSSFileName, clearError, clearSevereError, clearSevereError, clearStatus, close, close, closeAll, closeAllFiles, closeAndClear, closeDSSFile, debugLook, debugLook7, debugModify, defaultDirectory, defaultDSSFileName, doesDSSFileExist, done, DSSFileName, fileAccessible, fileOpened, fileStatus, flushMessages, forceMultiUserAccess, getCollectionList, getCollectionSequenceList, getCollectionSize, getDssFileVersion, getDssFileVersion, getFileInfo, getFileLastWriteTime, getFileLastWriteTimeMillis, getIrregBeginningDate, getLastError, getMessageLevel, getNumberRecords, getProcessStatus, getTimeSeriesExtents, getTSRecordInfo, isFileRemote, lastSevereErrorMessage, nextTimeSeriesPathname, numberRecords, open, open, processStatus, requestSecondAccess, setDefaultDirectory, setDefaultDSSFileName, setDss, setDSSFileName, setDSSFileName, setDSSFileName, setInterrupt, setMessageLevel, setSpaceReclaimation, setSpaceReclaimationPerm, setUnit, writeAccess, zgetMessageLevel, zinqir, zinqir, zinquire, zmessage, zquery, zquery, zset, zsetFile, zsetMessageLevel
-
Field Details
-
ERROR
public static final int ERROR- See Also:
-
UNKNOWN
public static final int UNKNOWN- See Also:
-
INT_ARRAY
public static final int INT_ARRAY- See Also:
-
FLOAT_ARRAY
public static final int FLOAT_ARRAY- See Also:
-
DOUBLE_ARRAY
public static final int DOUBLE_ARRAY- See Also:
-
LOCATION_LEVEL
public static final int LOCATION_LEVEL- See Also:
-
REGULAR_TIME_SERIES
public static final int REGULAR_TIME_SERIES- See Also:
-
REGULAR_TIME_PATTERN
public static final int REGULAR_TIME_PATTERN- See Also:
-
REGULAR_TIME_SERIES_DOUBLES
public static final int REGULAR_TIME_SERIES_DOUBLES- See Also:
-
IRREGULAR_TIME_SERIES
public static final int IRREGULAR_TIME_SERIES- See Also:
-
IRREGULAR_TIME_PATTERN
public static final int IRREGULAR_TIME_PATTERN- See Also:
-
IRREGULAR_TIME_SERIES_DOUBLES
public static final int IRREGULAR_TIME_SERIES_DOUBLES- See Also:
-
PAIRED
public static final int PAIRED- See Also:
-
PAIRED_DOUBLES
public static final int PAIRED_DOUBLES- See Also:
-
TEXT
public static final int TEXT- See Also:
-
SINGLE_VALUE
public static final int SINGLE_VALUE- See Also:
-
UNDEFINED_GRID_WITH_TIME
public static final int UNDEFINED_GRID_WITH_TIME- See Also:
-
UNDEFINED_GRID
public static final int UNDEFINED_GRID- See Also:
-
UNDEFINED_GRID_TYPE
public static final int UNDEFINED_GRID_TYPE- See Also:
-
HRAP_GRID_WITH_TIME
public static final int HRAP_GRID_WITH_TIME- See Also:
-
HRAP_GRID
public static final int HRAP_GRID- See Also:
-
HRAP
public static final int HRAP- See Also:
-
ALBERS_GRID_WITH_TIME
public static final int ALBERS_GRID_WITH_TIME- See Also:
-
ALBERS_GRID
public static final int ALBERS_GRID- See Also:
-
ALBERS
public static final int ALBERS- See Also:
-
SPECIFIED_GRID_WITH_TIME
public static final int SPECIFIED_GRID_WITH_TIME- See Also:
-
SPECIFIED_GRID
public static final int SPECIFIED_GRID- See Also:
-
SPECIFIED_GRID_TYPE
public static final int SPECIFIED_GRID_TYPE- See Also:
-
FILE
public static final int FILE- See Also:
-
IMAGE
public static final int IMAGE- See Also:
-
UNDEFINED_UNITS
public static final int UNDEFINED_UNITS- See Also:
-
ENGLISH_UNITS
public static final int ENGLISH_UNITS- See Also:
-
SI_UNITS
public static final int SI_UNITS- See Also:
-
_defaultStartTime
-
_defaultEndTime
-
_dssPathname
-
_dirty
protected boolean _dirty -
_slashPosition
protected int[] _slashPosition -
_startTime
-
_endTime
-
_arrayStartTime
-
_arrayEndTime
-
_timeWindowSet
protected boolean _timeWindowSet -
_arraySize
protected int _arraySize -
_desiredArraySize
protected int _desiredArraySize -
_recordType
protected int _recordType -
_checkedNumber
protected int _checkedNumber -
_dataLengthInts
protected int _dataLengthInts -
_dataType
protected int _dataType -
_localUnitSystem
protected int _localUnitSystem -
_recordExists
protected boolean _recordExists -
_timeSeries
protected boolean _timeSeries -
_unitsX
-
_typeX
-
-
Constructor Details
-
HecDSSDataAttributes
public HecDSSDataAttributes()
-
-
Method Details
-
createObject
-
createTimeSeriesObject
-
createPairedDataObject
-
createTextObject
-
createArrayObject
-
setDSSFileName
- Overrides:
setDSSFileNamein classHecDSSFileAccess
-
setDefaultAPart
-
setDefaultBPart
-
setDefaultCPart
-
setDefaultDPart
-
setDefaultEPart
-
setDefaultFPart
-
clearDefaultParts
public static void clearDefaultParts() -
defaultAPart
-
defaultBPart
-
defaultCPart
-
defaultDPart
-
defaultEPart
-
defaultFPart
-
aPart
-
bPart
-
cPart
-
dPart
-
ePart
-
fPart
-
pathname
- Overrides:
pathnamein classHecDssCatalog
-
setAPart
-
setBPart
-
setCPart
-
setDPart
-
setEPart
-
setFPart
-
setPathname
-
setPathnameParts
-
setDefaultPathnameParts
-
dirty
public boolean dirty() -
pathnameDataType
Tries to determine data type quickly from pathname only, without accessing the DSS file. This is meant to be quick For a more comprehensive and accurate value, use recordType.- Parameters:
pathname- String- Returns:
- int
-
recordsUpdated
public int recordsUpdated(long startTime, List<String> pathnames, List<Long> updateTimes, List<Integer> recordTypes) Retrieves infomation about record updated since the specified time.Any of the vector parameters may be null if that information is not required. Any of the vectors that are not null are cleared before being populated.
- Parameters:
startTime- Time after which to report updated records - in Java millisecondspathnames- The list of pathnames of the records that have been updated - may be null.updateTimes- The list of update times of the records that have been updated - may be null.recordTypes- The list of types of the records that have been updated - may be null.- Returns:
- Zero if successful.
-
recordTypes
-
recordType
-
recordType
public int recordType() -
isGridRecord
Determines if record for the given pathname is represents a grid.- Parameters:
pathname-- Returns:
-
recordExists
-
getLastWriteTimeMillis
public long getLastWriteTimeMillis() -
getLastWriteTimeMillis
-
getLastWriteTime
-
getLastWriteTime
-
getRecordBasics
-
setStartTime
-
setEndTime
-
setTimeWindow
-
setTimeWindow
-
setDefaultTimeWindow
-
setDefaultTimeWindow
-
startTime
-
arrayStartTime
-
endTime
-
arrayEndTime
-
isTimeWindowSet
public boolean isTimeWindowSet() -
setLocalUnitSystem
public void setLocalUnitSystem(int localUnitSystem) -
localUnitSystem
public int localUnitSystem() -
convertUnits
public static int convertUnits(double[] data, int number, int fromUnitSyst, int toUnitSyst, stringContainer units) -
convertDoubleUnits
public static int convertDoubleUnits(double[] data, int number, int fromUnits, int toUnits) -
status
public void status() -
readRawBytes
public byte[] readRawBytes() -
readRawBytes
public byte[] readRawBytes(int[] internalHeader, int limitInternalHeader, int[] numberInternalHeader, int[] compressionHeader, int limitCompressionHeader, int[] numberCompressionHeader, int[] userHeader, int limitUserHeader, int[] numberUserHeader, int[] stat) -
readRawRecord
-
writeRawRecord
-
readRawShorts
public short[] readRawShorts() -
readRawShorts
public short[] readRawShorts(int[] internalHeader, int limitInternalHeader, int[] numberInternalHeader, int[] compressionHeader, int limitCompressionHeader, int[] numberCompressionHeader, int[] userHeader, int limitUserHeader, int[] numberUserHeader, int[] stat)
-