jahiapagenotfoundexception.java

来自「java 写的一个新闻发布系统」· Java 代码 · 共 74 行

JAVA
74
字号
// $Id: JahiaPageNotFoundException.java,v 1.1.1.1 2002/02/07 15:09:15 loom Exp $//////                                   ____.//                       __/\ ______|    |__/\.     _______//            __   .____|    |       \   |    +----+       \//    _______|  /--|    |    |    -   \  _    |    :    -   \_________//   \\______: :---|    :    :           |    :    |         \________>//           |__\---\_____________:______:    :____|____:_____\//                                      /_____|////                 . . . i n   j a h i a   w e   t r u s t . . .//package org.jahia.exceptions;import org.jahia.exceptions.JahiaException;/** * This exception is raised when a page object is requested and is not * present in the database. * * @author  Fulco Houkes * @version 1.0 */public class JahiaPageNotFoundException extends JahiaException{    private int mPageID;    //-------------------------------------------------------------------------    /** Default constructor     *     * @param   pageID  The not-found requested page ID.     */    public JahiaPageNotFoundException (int pageID)    {        super ("404 Not found - Page:" + pageID,               "404 error - page ["+pageID+"] could not be found in the database.",               PAGE_ERROR, ERROR);        mPageID = pageID;    }    //-------------------------------------------------------------------------    /** Constructor     *     * @param   pageIDStr  The not-found requested page ID string.     */    public JahiaPageNotFoundException (String pageIDStr)    {        super ("404 Not found - Page:" + pageIDStr,               "404 error - page ["+pageIDStr+"] could not be found in the database.",               PAGE_ERROR, ERROR);        try {            mPageID = Integer.parseInt (pageIDStr);        }        catch (NumberFormatException ex) {            mPageID = -1;        }    }    //-------------------------------------------------------------------------    /** Return the ID of the not found page.     */    public final int getPageID () {        return mPageID;    }}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?