001/*
002 * Licensed to the Apache Software Foundation (ASF) under one or more
003 * contributor license agreements.  See the NOTICE file distributed with
004 * this work for additional information regarding copyright ownership.
005 * The ASF licenses this file to You under the Apache License, Version 2.0
006 * (the "License"); you may not use this file except in compliance with
007 * the License.  You may obtain a copy of the License at
008 *
009 *      http://www.apache.org/licenses/LICENSE-2.0
010 *
011 * Unless required by applicable law or agreed to in writing, software
012 * distributed under the License is distributed on an "AS IS" BASIS,
013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
014 * See the License for the specific language governing permissions and
015 * limitations under the License.
016 */
017package org.apache.wicket.jmx;
018
019/**
020 * Debug settings.
021 * 
022 * @author eelcohillenius
023 */
024public interface DebugSettingsMBean
025{
026        /**
027         * @return true if componentUseCheck is enabled
028         */
029        boolean getComponentUseCheck();
030
031        /**
032         * Returns status of ajax debug mode.
033         * 
034         * @return true if ajax debug mode is enabled, false otherwise
035         * 
036         */
037        boolean isAjaxDebugModeEnabled();
038
039        /**
040         * Enables or disables ajax debug mode.
041         * 
042         * @param enable
043         * 
044         */
045        void setAjaxDebugModeEnabled(boolean enable);
046
047        /**
048         * Sets componentUseCheck debug settings
049         * 
050         * @param check
051         */
052        void setComponentUseCheck(boolean check);
053
054
055        /**
056         * If the parameter value is non-empty then Wicket will use it as the name of an attribute of the
057         * component tag to print the {@link org.apache.wicket.Component}'s path.
058         * 
059         * @param name
060         */
061        void setComponentPathAttributeName(String name);
062
063        /**
064         * @see #setComponentPathAttributeName(String)
065         * @return The name of the attribute for the {@link org.apache.wicket.markup.ComponentTag}.
066         *         If {@code null} or empty then the attribute won't be rendered
067         */
068        String getComponentPathAttributeName();
069
070        /**
071         * Enables wrapping output of markup container in html comments that contain markup container's
072         * class name. (Useful for determining which part of page belongs to which markup file).
073         * 
074         * @param enable
075         */
076        void setOutputMarkupContainerClassName(boolean enable);
077
078        /**
079         * Returns whether the output of markup container's should be wrapped by comments containing the
080         * container's class name.
081         * 
082         * @return true if the markup container's class name should be written to response
083         */
084        boolean isOutputMarkupContainerClassName();
085
086        /**
087         * Returns status of line precise error reporting for added components that are not present in
088         * the markup: it points to the line where the component was added to the hierarchy in your Java
089         * classes. This can cause a significant decrease in performance, do not use in customer facing
090         * applications.
091         * 
092         * @return true if the line precise error reporting is enabled
093         */
094        boolean isLinePreciseReportingOnAddComponentEnabled();
095
096        /**
097         * Enables line precise error reporting for added components that are not present in the markup:
098         * it points to the line where the component was added to the hierarchy in your Java classes.
099         * This can cause a significant decrease in performance, do not use in customer facing
100         * applications.
101         * 
102         * @param enable
103         */
104        void setLinePreciseReportingOnAddComponentEnabled(boolean enable);
105
106        /**
107         * Returns status of line precise error reporting for new components that are not present in the
108         * markup: it points to the line where the component was created in your Java classes. This can
109         * cause a significant decrease in performance, do not use in customer facing applications.
110         * 
111         * @return true if the line precise error reporting is enabled
112         */
113        boolean isLinePreciseReportingOnNewComponentEnabled();
114
115        /**
116         * Enables line precise error reporting for new components that are not present in the markup:
117         * it points to the line where the component was created in your Java classes. This can cause a
118         * significant decrease in performance, do not use in customer facing applications.
119         * 
120         * @param enable
121         */
122        void setLinePreciseReportingOnNewComponentEnabled(boolean enable);
123
124        /**
125         * Enables all of the panels and pages, etc, from wicket-devutils package.
126         * 
127         * @param enable
128         */
129        void setDevelopmentUtilitiesEnabled(boolean enable);
130
131        /**
132         * Are all of the panels and pages, etc, from wicket-devutils package enabled?
133         * 
134         * @return true if all of the panels and pages, etc, from wicket-devutils package are enabled
135         */
136        boolean isDevelopmentUtilitiesEnabled();
137}