Latest bnd code
git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@1350613 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/bundleplugin/src/main/java/aQute/lib/index/Index.java b/bundleplugin/src/main/java/aQute/lib/index/Index.java
index 4414f9d..da19f68 100644
--- a/bundleplugin/src/main/java/aQute/lib/index/Index.java
+++ b/bundleplugin/src/main/java/aQute/lib/index/Index.java
@@ -12,8 +12,6 @@
* 123 -> 123, 244 -> 2
* 245 -> 245, ...
* </pre>
- *
- *
*/
public class Index implements Iterable<byte[]> {
final static int LEAF = 0;
@@ -29,7 +27,7 @@
final int valueSize = 8;
final int capacity;
public Page root;
- final LinkedHashMap<Integer, Page> cache = new LinkedHashMap<Integer, Index.Page>();
+ final LinkedHashMap<Integer,Page> cache = new LinkedHashMap<Integer,Index.Page>();
final MappedByteBuffer settings;
private int nextPage;
@@ -81,7 +79,8 @@
i = getPage(c).iterator();
}
return i.hasNext();
- } catch (IOException e) {
+ }
+ catch (IOException e) {
throw new RuntimeException(e);
}
@@ -246,7 +245,8 @@
StringBuilder sb = new StringBuilder();
try {
toString(sb, "");
- } catch (IOException e) {
+ }
+ catch (IOException e) {
e.printStackTrace();
}
return sb.toString();
@@ -254,8 +254,8 @@
public void toString(StringBuilder sb, String indent) throws IOException {
for (int i = 0; i < n; i++) {
- sb.append(String.format("%s %02d:%02d %20s %s %d\n", indent, number, i,
- hex(k(i), 0, 4), leaf ? "==" : "->", c(i)));
+ sb.append(String.format("%s %02d:%02d %20s %s %d\n", indent, number, i, hex(k(i), 0, 4), leaf ? "=="
+ : "->", c(i)));
if (!leaf) {
long c = c(i);
Page sub = getPage((int) c);
@@ -303,8 +303,8 @@
this.keySize = settings.getInt(KEYSIZE);
if (keySize != 0 && this.keySize != keySize)
- throw new IllegalStateException("Invalid key size for Index file. The file is "
- + this.keySize + " and was expected to be " + this.keySize);
+ throw new IllegalStateException("Invalid key size for Index file. The file is " + this.keySize
+ + " and was expected to be " + this.keySize);
root = getPage(1);
nextPage = (int) (this.file.size() / pageSize);