(String directory, String fileName)
| 302 | private boolean acquisitionSequence; |
| 303 | |
| 304 | public DicomDecoder(String directory, String fileName) { |
| 305 | this.directory = directory; |
| 306 | this.fileName = fileName; |
| 307 | String path = null; |
| 308 | if (dictionary==null && IJ.getApplet()==null) { |
| 309 | path = Prefs.getImageJDir()+"DICOM_Dictionary.txt"; |
| 310 | File f = new File(path); |
| 311 | if (f.exists()) try { |
| 312 | dictionary = new Properties(); |
| 313 | InputStream is = new BufferedInputStream(new FileInputStream(f)); |
| 314 | dictionary.load(is); |
| 315 | is.close(); |
| 316 | if (IJ.debugMode) IJ.log("DicomDecoder: using "+dictionary.size()+" tag dictionary at "+path); |
| 317 | } catch (Exception e) { |
| 318 | dictionary = null; |
| 319 | } |
| 320 | } |
| 321 | if (dictionary==null) { |
| 322 | DicomDictionary d = new DicomDictionary(); |
| 323 | dictionary = d.getDictionary(); |
| 324 | if (IJ.debugMode) IJ.log("DicomDecoder: "+path+" not found; using "+dictionary.size()+" tag built in dictionary"); |
| 325 | } |
| 326 | } |
| 327 | |
| 328 | String getString(int length) throws IOException { |
| 329 | byte[] buf = new byte[length]; |
nothing calls this directly
no test coverage detected