Mercurial > hg4j
comparison src/org/tmatesoft/hg/repo/HgRepository.java @ 621:99ad1e3a4e4d
RevlogStream: be aware of existence (not HgDataFile), facilitate use of an added HgDataFile over a commit; Rollback: be more sensitive about file changes (file size is not enough: write/rollback leaves it intact); tests
author | Artem Tikhomirov <tikhomirov.artem@gmail.com> |
---|---|
date | Sat, 18 May 2013 22:23:57 +0200 |
parents | 272ecffccc8a |
children | 6526d8adbc0f |
comparison
equal
deleted
inserted
replaced
620:272ecffccc8a | 621:99ad1e3a4e4d |
---|---|
240 return getFileNode(p); | 240 return getFileNode(p); |
241 } | 241 } |
242 | 242 |
243 public HgDataFile getFileNode(Path path) { | 243 public HgDataFile getFileNode(Path path) { |
244 RevlogStream content = impl.resolveStoreFile(path); | 244 RevlogStream content = impl.resolveStoreFile(path); |
245 if (content == null) { | 245 assert content != null; |
246 return new HgDataFile(this, path); | |
247 } | |
248 return new HgDataFile(this, path, content); | 246 return new HgDataFile(this, path, content); |
249 } | 247 } |
250 | 248 |
251 /* clients need to rewrite path from their FS to a repository-friendly paths, and, perhaps, vice versa*/ | 249 /* clients need to rewrite path from their FS to a repository-friendly paths, and, perhaps, vice versa*/ |
252 public PathRewrite getToRepoPathHelper() { | 250 public PathRewrite getToRepoPathHelper() { |