@Test public void testConvertToInt() { DdlInfoFileImpl ddlInfoFile = new DdlInfoFileImpl(new File("file")); assertEquals(10, ddlInfoFile.convertToInt("10")); }
protected int convertToInt(String value) { int versionNo; try { versionNo = Integer.valueOf(value); } catch (NumberFormatException e) { throw new IllegalDdlInfoVersionRuntimeException(file.getPath(), value); } if (versionNo < 0) { throw new IllegalDdlInfoVersionRuntimeException(file.getPath(), value); } return versionNo; }
DdlInfoFileImpl implements DdlInfoFile { protected int convertToInt(String value) { int versionNo; try { versionNo = Integer.valueOf(value); } catch (NumberFormatException e) { throw new IllegalDdlInfoVersionRuntimeException(file.getPath(), value); } if (versionNo < 0) { throw new IllegalDdlInfoVersionRuntimeException(file.getPath(), value); } return versionNo; } }
DdlInfoFileImpl implements DdlInfoFile { protected int convertToInt(String value) { int versionNo; try { versionNo = Integer.valueOf(value); } catch (NumberFormatException e) { throw new IllegalDdlInfoVersionRuntimeException(file.getPath(), value); } if (versionNo < 0) { throw new IllegalDdlInfoVersionRuntimeException(file.getPath(), value); } return versionNo; } DdlInfoFileImpl(File file); }
DdlInfoFileImpl implements DdlInfoFile { protected int convertToInt(String value) { int versionNo; try { versionNo = Integer.valueOf(value); } catch (NumberFormatException e) { throw new IllegalDdlInfoVersionRuntimeException(file.getPath(), value); } if (versionNo < 0) { throw new IllegalDdlInfoVersionRuntimeException(file.getPath(), value); } return versionNo; } DdlInfoFileImpl(File file); int getCurrentVersionNo(); int getNextVersionNo(); void applyNextVersionNo(String comment); }
DdlInfoFileImpl implements DdlInfoFile { protected int convertToInt(String value) { int versionNo; try { versionNo = Integer.valueOf(value); } catch (NumberFormatException e) { throw new IllegalDdlInfoVersionRuntimeException(file.getPath(), value); } if (versionNo < 0) { throw new IllegalDdlInfoVersionRuntimeException(file.getPath(), value); } return versionNo; } DdlInfoFileImpl(File file); int getCurrentVersionNo(); int getNextVersionNo(); void applyNextVersionNo(String comment);  }