long getCapacity() throws IOException { if (reserved > usage.getCapacity()) { return 0; } return usage.getCapacity() - reserved; }