⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mvnforumconfig.java

📁 解觖java技术中后台无法上传数给的情况
💻 JAVA
📖 第 1 页 / 共 3 页
字号:
     * By default, mvnForum disable passwordless authentication
     * If you want to authenticate user from realm or customized methods,
     * then set the variable to true (AT YOUR OWN RISK, although I have not
     * found any security issues until now)
     */
    private static boolean ENABLE_PASSWORDLESS_AUTH = false;
    public static boolean getEnablePasswordlessAuth() {
        return ENABLE_PASSWORDLESS_AUTH;
    }

    private static boolean REQUIRE_ACTIVATION = false;
    public static boolean getRequireActivation() {
        return REQUIRE_ACTIVATION;
    }

    private static boolean ENABLE_LOGIN_INFO_IN_COOKIE = true;
    public static boolean getEnableLoginInfoInCookie() {
        return ENABLE_LOGIN_INFO_IN_COOKIE;
    }

    private static boolean ENABLE_LOGIN_INFO_IN_SESSION = true;
    public static boolean getEnableLoginInfoInSession() {
        return ENABLE_LOGIN_INFO_IN_SESSION;
    }

    private static boolean ENABLE_LOGIN_INFO_IN_REALM = false;
    public static boolean getEnableLoginInfoInRealm() {
        return ENABLE_LOGIN_INFO_IN_REALM;
    }

    private static boolean ENABLE_LOGIN_INFO_IN_CUSTOMIZATION = false;
    public static boolean getEnableLoginInfoInCustomization() {
        return ENABLE_LOGIN_INFO_IN_CUSTOMIZATION;
    }

    private static boolean ENABLE_LOGIN = true;
    public static boolean getEnableLogin() {
        return ENABLE_LOGIN;
    }

    private static boolean ENABLE_CACHE_MEMBER = true;
    public static boolean getEnableCacheMember() {
        return ENABLE_CACHE_MEMBER;
    }

    private static boolean ENABLE_CACHE_POST = true;
    public static boolean getEnableCachePost() {
        return ENABLE_CACHE_POST;
    }

    private static boolean ENABLE_CACHE_THREAD = true;
    public static boolean getEnableCacheThread() {
        return ENABLE_CACHE_THREAD;
    }

    private static boolean ENABLE_CACHE_FORUM = true;
    public static boolean getEnableCacheForum() {
        return ENABLE_CACHE_FORUM;
    }

    private static boolean ENABLE_CACHE_CATEGORY = true;
    public static boolean getEnableCacheCategory() {
        return ENABLE_CACHE_CATEGORY;
    }

    private static boolean ENABLE_GUEST_VIEW_IMAGE_ATTACHMENT = false;
    public static boolean getEnableGuestViewImageAttachment() {
        return ENABLE_GUEST_VIEW_IMAGE_ATTACHMENT;
    }

    //设置是否可以增加新会员
    private static boolean ENABLE_NEW_MEMBER = true;
    public static boolean getEnableNewMember() {
        return ENABLE_NEW_MEMBER;
    }

    private static boolean ENABLE_NEW_POST = true;
    public static boolean getEnableNewPost() {
        return ENABLE_NEW_POST;
    }

    private static boolean ENABLE_AVATAR = true;
    public static boolean getEnableAvatar() {
        return ENABLE_AVATAR;
    }

    private static boolean ENABLE_EMOTICON = true;
    public static boolean getEnableEmoticon() {
        return ENABLE_EMOTICON;
    }

    private static boolean ENABLE_RSS = true;
    public static boolean getEnableRSS() {
        return ENABLE_RSS;
    }

    private static boolean ENABLE_SEARCH = true;
    public static boolean getEnableSearch() {
        return ENABLE_SEARCH;
    }
    private static boolean ENABLE_WATCH = true;
    public static boolean getEnableWatch() {
        return ENABLE_WATCH;
    }

    private static boolean ENABLE_ATTACHMENT = true;
    public static boolean getEnableAttachment() {
        return ENABLE_ATTACHMENT;
    }

    private static boolean ENABLE_MESSAGE_ATTACHMENT = true;
    public static boolean getEnableMessageAttachment() {
        return ENABLE_MESSAGE_ATTACHMENT;
    }

    private static boolean ENABLE_MOST_ACTIVE_THREADS = true;
    public static boolean getEnableMostActiveThreads() {
        return ENABLE_MOST_ACTIVE_THREADS;
    }

    private static boolean ENABLE_MOST_ACTIVE_MEMBERS = true;
    public static boolean getEnableMostActiveMembers() {
        return ENABLE_MOST_ACTIVE_MEMBERS;
    }

    private static boolean ENABLE_SITE_STATISTICS_OVERVIEW = true;
    public static boolean getEnableSiteStatisticsOverview() {
        return ENABLE_SITE_STATISTICS_OVERVIEW;
    }

    private static int MAX_ATTACHMENT_SIZE = 1024;
    public static int getMaxAttachmentSize() {
        return MAX_ATTACHMENT_SIZE;
    }

    private static int MAX_MESSAGE_ATTACHMENT_SIZE = 1024;
    public static int getMaxMessageAttachmentSize() {
        return MAX_MESSAGE_ATTACHMENT_SIZE;
    }

    // Default is false, but in KG it should be true
    private static boolean ENABLE_AUTO_FORUM_OWNER = false;
    public static boolean getEnableAutoForumOwner() {
        return ENABLE_AUTO_FORUM_OWNER;
    }

    private static boolean ENABLE_CAPTCHA = false;
    public static boolean getEnableCaptcha() {
        return ENABLE_CAPTCHA;
    }

    private static boolean ENABLE_PORTAL_LIKE_INDEX_PAGE = true;
    public static boolean getEnablePortalLikeIndexPage() {
        return ENABLE_PORTAL_LIKE_INDEX_PAGE;
    }

    private static boolean ENABLE_ADMIN_CAN_CHANGE_PASSWORD = true;
    public static boolean getEnableAdminCanChangePassword() {
        return ENABLE_ADMIN_CAN_CHANGE_PASSWORD;
    }

    private static boolean ENABLE_SHOW_LAST_LOGIN = true;
    public static boolean getEnableShowLastLogin() {
        return ENABLE_SHOW_LAST_LOGIN;
    }

    private static boolean ENABLE_ONLINE_USERS = true;
    public static boolean getEnableOnlineUsers() {
        return ENABLE_ONLINE_USERS;
    }

    private static boolean ENABLE_DUPLICATE_ONLINE_USERS = true;
    public static boolean getEnableDuplicateOnlineUsers() {
        return ENABLE_DUPLICATE_ONLINE_USERS;
    }

    private static boolean ENABLE_INVISIBLE_USERS = true;
    public static boolean getEnableInvisibleUsers() {
        return ENABLE_INVISIBLE_USERS;
    }

    private static boolean ENABLE_LISTMEMBERS = true;
    public static boolean getEnableListMembers() {
        return ENABLE_LISTMEMBERS;
    }

    private static boolean ENABLE_PRIVATE_MESSAGE = true;
    public static boolean getEnablePrivateMessage() {
        return ENABLE_PRIVATE_MESSAGE;
    }

    private static boolean ENABLE_PUBLIC_MESSAGE = true;
    public static boolean getEnablePublicMessage() {
        return ENABLE_PUBLIC_MESSAGE;
    }

    // Default is false, but in Marco it should be true
    private static boolean ENABLE_COMPANY = false;
    public static boolean getEnableCompany() {
        return ENABLE_COMPANY;
    }

    // Default is false, but in Marco it should be true or false
    private static boolean ENABLE_LISTCOMPANIES = false;
    public static boolean getEnableListCompanies() {
        return ENABLE_LISTCOMPANIES;
    }

    private static int EXPIRE_DATE_TUTOR = 90;
    public static int getExpireDateTutor() {
        return EXPIRE_DATE_TUTOR;
    }

    private static int EXPIRE_SOON_DATE = 7;
    public static int getUserTutorExpireSoonDate() {
        return EXPIRE_SOON_DATE;
    }

    /**
     * This is the maximum number of favorite threads that a user can add
     */
    private static int MAX_FAVORITE_THREAD = 128;
    public static int getMaxFavoriteThread() {
        return MAX_FAVORITE_THREAD;
    }

    private static int MAX_PRIVATE_MESSAGE = 128;
    public static int getMaxPrivateMessage() {
        return MAX_PRIVATE_MESSAGE;
    }

    private static int HOT_TOPIC_THRESHOLD = 10;
    public static int getHotTopicThreshold() {
        return HOT_TOPIC_THRESHOLD;
    }

    private static int MAX_POSTS_PER_HOUR = 20;
    public static int getMaxPostsPerHour() {
        return MAX_POSTS_PER_HOUR;
    }

    private static int MAX_MEMBERS_PER_HOUR = 2;
    public static int getMaxMembersPerHour() {
        return MAX_MEMBERS_PER_HOUR;
    }

    private static int MAX_LOGINS_PER_HOUR = 5;
    public static int getMaxLoginsPerHour() {
        return MAX_LOGINS_PER_HOUR;
    }

    private static int MAX_MESSAGES_PER_HOUR = 5;
    public static int getMaxMessagesPerHour() {
        return MAX_MESSAGES_PER_HOUR;
    }

    private static int MAX_ACTIVE_THREADS = 5;
    public static int getMaxActiveThreads() {
        return MAX_ACTIVE_THREADS;
    }

    private static int MAX_ACTIVE_MEMBERS = 5;
    public static int getMaxActiveMembers() {
        return MAX_ACTIVE_MEMBERS;
    }

    /** Do we allow storing backup files on the server? Currently not used. */
    static boolean ENABLE_BACKUP_ON_SERVER = true;
    public static final String BACKUP_FILE_PREFIX = "mvnForum-";
    public static final String BACKUP_FILE_MainXmlFileNameInZip = "IMPORT.xml";
    public static final String BACKUP_FILE_AvatarsDirNameInZip = "AVATARS/"; //must end with '/'
    public static final String BACKUP_FILE_AttachsDirNameInZip = "ATTACHMENTS/"; //must end with '/'

    /**
     * Maximum size of the import file (in bytes) we will allow to be uploaded
     * to server before processing.
     */
    private static int MAX_IMPORT_SIZE = 4096000;
    /**
     * Maximum size of the import file (in bytes) we will allow to be uploaded
     * to server before processing.
     */
    public static int getMaxImportSize() {
        return MAX_IMPORT_SIZE;
    }

    /**
     * Type of import/export file: mvnForum XML.
     * Import only database info, no attachments, message folders, avatars, ...
     */
    public static final int IMPORTEXPORT_TYPE_MVN_XML  = 0;

    /**
     * Type of import file: mvnForum ZIP.
     * Also import attachments, avatars, message folders
     */
    public static final int IMPORTEXPORT_TYPE_MVN_ZIP  = 1;

    /**
     * Type of import file: Jive XML.
     * Using <code>http://www.jivesoftware.com/jive.dtd</code>, xmlversion="1.0".
     */
    public static final int IMPORTEXPORT_TYPE_JIVE_XML = 2;

    /**
     * Output all messages, including errors, important messages and
     * informational/status messages. This constant is used for specifing
     * the level of output in various processess throughout the application.
     */
    public static final int MESSAGE_LEVEL_ALL_MESSAGES       = 0;

    /**
     * Output only error messages and important messages (no
     * informational/status messages). This constant is used for specifing
     * the level of output in various processess throughout the application.
     */
    public static final int MESSAGE_LEVEL_IMPORTANT_MESSAGES = 1;

    /**
     * Output only error messages (no important messages, no
     * informational/status messages). This constant is used for specifing
     * the level of output in various processess throughout the application.
     */
    public static final int MESSAGE_LEVEL_ONLY_ERRORS        = 2;

    public final static long SESSION_DURATION    = 30 * DateUtil.MINUTE;// SHOULD NOT less than 15 minutes

    //public static final boolean DEFAULT_MESSAGE_ENABLE  = true;
    //public static final boolean DEFAULT_MEMBER_ENABLE   = true;

    /**
     * Configurable number of days that a user can edit a post
     */
    private static int MAX_EDIT_DAYS   = 7;
    public static int getMaxEditDays() {
        return MAX_EDIT_DAYS;
    }

    /**
     * Configurable number of days that a user can attach file to a post
     */
    private static int MAX_ATTACH_DAYS = 1;
    public static int getMaxAttachDays() {
        return MAX_ATTACH_DAYS;
    }

    /**
     * Configurable number of days that a user can delete a post
     */
    private static int MAX_DELETE_DAYS = 1;
    public static int getMaxDeleteDays() {
        return MAX_DELETE_DAYS;
    }

    /**

⌨️ 快捷键说明

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