Mercurial > jhg
comparison src/org/tmatesoft/hg/repo/HgDirstate.java @ 418:528b6780a8bd
A bit of FIXME cleanup (mostly degraded to TODO post 1.0), comments and javadoc
| author | Artem Tikhomirov <tikhomirov.artem@gmail.com> | 
|---|---|
| date | Thu, 22 Mar 2012 21:02:20 +0100 | 
| parents | 63c5a9d7ca3f | 
| children | fdd7d756dea0 | 
   comparison
  equal
  deleted
  inserted
  replaced
| 417:ccd7d25e5aea | 418:528b6780a8bd | 
|---|---|
| 21 import java.io.BufferedReader; | 21 import java.io.BufferedReader; | 
| 22 import java.io.File; | 22 import java.io.File; | 
| 23 import java.io.FileNotFoundException; | 23 import java.io.FileNotFoundException; | 
| 24 import java.io.FileReader; | 24 import java.io.FileReader; | 
| 25 import java.io.IOException; | 25 import java.io.IOException; | 
| 26 import java.nio.charset.CharacterCodingException; | |
| 27 import java.util.Collections; | 26 import java.util.Collections; | 
| 28 import java.util.HashMap; | 27 import java.util.HashMap; | 
| 29 import java.util.LinkedHashMap; | 28 import java.util.LinkedHashMap; | 
| 30 import java.util.Map; | 29 import java.util.Map; | 
| 31 import java.util.TreeSet; | 30 import java.util.TreeSet; | 
| 145 merged.put(r.name1, r); | 144 merged.put(r.name1, r); | 
| 146 } else { | 145 } else { | 
| 147 repo.getContext().getLog().warn(getClass(), "Dirstate record for file %s (size: %d, tstamp:%d) has unknown state '%c'", r.name1, r.size(), r.time, state); | 146 repo.getContext().getLog().warn(getClass(), "Dirstate record for file %s (size: %d, tstamp:%d) has unknown state '%c'", r.name1, r.size(), r.time, state); | 
| 148 } | 147 } | 
| 149 } | 148 } | 
| 150 } catch (CharacterCodingException ex) { | |
| 151 throw new HgInvalidControlFileException(String.format("Failed reading file names from dirstate using encoding %s", encodingHelper.charset().name()), ex, dirstateFile); | |
| 152 } catch (IOException ex) { | 149 } catch (IOException ex) { | 
| 153 throw new HgInvalidControlFileException("Dirstate read failed", ex, dirstateFile); | 150 throw new HgInvalidControlFileException("Dirstate read failed", ex, dirstateFile); | 
| 154 } finally { | 151 } finally { | 
| 155 da.done(); | 152 da.done(); | 
| 156 } | 153 } | 
