001 package crisp.wbwiki.server; 002 003 import crisp.wbwiki.client.Page; 004 005 /** 006 * Something that knows how to store and load wiki data persistently. 007 * 008 * Currently supports only single page text-only wikis :o) 009 * 010 * @author Henrik Kniberg 011 */ 012 public interface WikiDb { 013 /** 014 * Never null. May be empty though. 015 */ 016 public Page loadPage(); 017 018 /** 019 * Null will be treated as an empty page. 020 * @return the new version 021 */ 022 public int savePage(String content); 023 024 public int getCurrentVersion(); 025 }