public class InstallServlet
extends javax.servlet.http.HttpServlet
限定符和类型 | 字段和说明 |
---|---|
private AbstractCmsUpgrader |
cmsUpgrader |
private freemarker.template.Configuration |
freemarkerConfiguration |
private java.lang.String |
fromVersion |
private org.apache.commons.logging.Log |
log |
private static long |
serialVersionUID |
private java.lang.String |
startStep |
static java.lang.String |
STEP_CHECKDATABASE |
static java.lang.String |
STEP_DATABASECONFIG |
static java.lang.String |
STEP_INITDATABASE |
static java.lang.String |
STEP_START |
static java.lang.String |
STEP_UPDATE |
构造器和说明 |
---|
InstallServlet(java.lang.String startStep,
java.lang.String fromVersion) |
限定符和类型 | 方法和说明 |
---|---|
private void |
checkDatabse(javax.servlet.http.HttpServletRequest request,
java.util.Map<java.lang.String,java.lang.Object> map)
检查数据库
|
private void |
configDatabase(javax.servlet.http.HttpServletRequest request,
java.util.Map<java.lang.String,java.lang.Object> map)
配置数据库
|
protected void |
doGet(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response) |
protected void |
doPost(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response) |
private static java.lang.String |
getSiteUrl(javax.servlet.http.HttpServletRequest request) |
private void |
initDatabase(java.lang.String useSimple,
java.lang.String username,
java.lang.String password,
java.lang.String siteurl,
java.util.Map<java.lang.String,java.lang.Object> map)
初始化数据库
|
private java.lang.String |
install(java.sql.Connection connection,
java.lang.String username,
java.lang.String password,
java.lang.String siteurl,
boolean useSimple) |
private void |
render(java.lang.String step,
java.util.Locale locale,
java.util.Map<java.lang.String,java.lang.Object> model,
javax.servlet.http.HttpServletResponse response) |
private void |
start() |
private void |
startCMS(java.util.Map<java.lang.String,java.lang.Object> map)
启动CMS
|
private void |
upgradeDatabase(java.lang.String version,
java.util.Map<java.lang.String,java.lang.Object> map)
升级数据库
|
doDelete, doHead, doOptions, doPut, doTrace, getLastModified, service, service
private static final long serialVersionUID
public static final java.lang.String STEP_CHECKDATABASE
public static final java.lang.String STEP_DATABASECONFIG
public static final java.lang.String STEP_INITDATABASE
public static final java.lang.String STEP_UPDATE
public static final java.lang.String STEP_START
private final org.apache.commons.logging.Log log
private freemarker.template.Configuration freemarkerConfiguration
private java.lang.String startStep
private java.lang.String fromVersion
private AbstractCmsUpgrader cmsUpgrader
public InstallServlet(java.lang.String startStep, java.lang.String fromVersion)
startStep
- fromVersion
- protected void doGet(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws javax.servlet.ServletException, java.io.IOException
doGet
在类中 javax.servlet.http.HttpServlet
javax.servlet.ServletException
java.io.IOException
protected void doPost(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws javax.servlet.ServletException, java.io.IOException
doPost
在类中 javax.servlet.http.HttpServlet
javax.servlet.ServletException
java.io.IOException
private void start() throws java.io.IOException
java.io.IOException
private void configDatabase(javax.servlet.http.HttpServletRequest request, java.util.Map<java.lang.String,java.lang.Object> map)
private void checkDatabse(javax.servlet.http.HttpServletRequest request, java.util.Map<java.lang.String,java.lang.Object> map)
map
- private static java.lang.String getSiteUrl(javax.servlet.http.HttpServletRequest request)
private void initDatabase(java.lang.String useSimple, java.lang.String username, java.lang.String password, java.lang.String siteurl, java.util.Map<java.lang.String,java.lang.Object> map) throws java.lang.ClassNotFoundException, java.sql.SQLException, java.io.IOException
useSimple
- username
- password
- map
- java.sql.SQLException
java.lang.ClassNotFoundException
java.io.IOException
private java.lang.String install(java.sql.Connection connection, java.lang.String username, java.lang.String password, java.lang.String siteurl, boolean useSimple) throws java.sql.SQLException, java.io.IOException
java.sql.SQLException
java.io.IOException
private void upgradeDatabase(java.lang.String version, java.util.Map<java.lang.String,java.lang.Object> map) throws java.lang.ClassNotFoundException, java.sql.SQLException, java.io.IOException
java.io.IOException
java.sql.SQLException
java.lang.ClassNotFoundException
private void startCMS(java.util.Map<java.lang.String,java.lang.Object> map)
private void render(java.lang.String step, java.util.Locale locale, java.util.Map<java.lang.String,java.lang.Object> model, javax.servlet.http.HttpServletResponse response)