Package org.dbwiki.exception.data

Examples of org.dbwiki.exception.data.WikiTimeException


   * Check that there are no duplicates and that the next version being added is the next in the sequence
   */
  public synchronized void add(Version version) throws org.dbwiki.exception.WikiException {
    //System.out.println("DEBUG: "+version.toString());
    if (_versionNameIndex.containsKey(version.name())) {
      throw new WikiTimeException(WikiTimeException.DuplicateVersion, "Version " + version.name() + " already exists");
    }
    if (version.number() != (_versionList.size() + 1)) {
      throw new WikiFatalException("Invalid version number " + version.number() + ". Expected number is " + (_versionList.size() + 1));
    }
   
View Full Code Here


      Version version = this.get(iVersion);
      if (version.number() == number) {
        return version;
      }
    }
    throw new WikiTimeException(WikiTimeException.UnknownVersionNumber, String.valueOf(number));
  }
View Full Code Here

TOP

Related Classes of org.dbwiki.exception.data.WikiTimeException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.