public final class SACUtil
extends java.lang.Object
修飾子とタイプ | メソッドと説明 |
---|---|
static Trace |
createTrace(java.nio.file.Path sacPath)
The trace is DEEP copied.
|
static java.util.Map<SACHeaderEnum,java.lang.String> |
readHeader(java.nio.file.Path sacPath)
Read header values in a sacFile.
|
static double[] |
readSACData(java.nio.file.Path sacPath)
Waveform in sac file.
|
static boolean |
rotate(java.nio.file.Path sacEPath,
java.nio.file.Path sacNPath,
java.nio.file.Path outputRPath,
java.nio.file.Path outputTPath)
By rotating hoge.E and hoge.N, write hoge.R and hoge.T The rotation is
done by SAC.
|
static void |
writeSAC(java.nio.file.Path outPath,
java.util.Map<SACHeaderEnum,java.lang.String> headerMap,
double[] data,
java.nio.file.OpenOption... options) |
public static boolean rotate(java.nio.file.Path sacEPath, java.nio.file.Path sacNPath, java.nio.file.Path outputRPath, java.nio.file.Path outputTPath) throws java.io.IOException
sacEPath
- SAC file which component is E. must exist.sacNPath
- SAC file which component is N. must exist.outputRPath
- for write SAC with respect to RoutputTPath
- for write SAC with respect to Tjava.io.IOException
- if an I/O error occurs. If sacEPath or sacNPath does not
exist, if write Paths already exist.public static void writeSAC(java.nio.file.Path outPath, java.util.Map<SACHeaderEnum,java.lang.String> headerMap, double[] data, java.nio.file.OpenOption... options) throws java.io.IOException
outPath
- for write (If the file exists, it will be overwritten)headerMap
- of write SACdata
- of write SAC. The length must be same as NPTS.options
- Options for writejava.io.IOException
- if an I/O error occurspublic static Trace createTrace(java.nio.file.Path sacPath) throws java.io.IOException
sacPath
- to extract waveform fromTrace
from waveform in the sacFilejava.io.IOException
- If sacFile does not exist, if an I/O error occurs.public static java.util.Map<SACHeaderEnum,java.lang.String> readHeader(java.nio.file.Path sacPath) throws java.io.IOException
sacPath
- to readMap
of SACHeader
in the filejava.io.IOException
- If sacFile does not exist, if an I/O error occurs.public static double[] readSACData(java.nio.file.Path sacPath) throws java.io.IOException
sacPath
- Path
for a sac filejava.io.IOException
- if sacPath does not exist or if an I/O error occurs