01: /*
02: * Licensed to the Apache Software Foundation (ASF) under one or more
03: * contributor license agreements. See the NOTICE file distributed with
04: * this work for additional information regarding copyright ownership.
05: * The ASF licenses this file to You under the Apache License, Version 2.0
06: * (the "License"); you may not use this file except in compliance with
07: * the License. You may obtain a copy of the License at
08: *
09: * http://www.apache.org/licenses/LICENSE-2.0
10: *
11: * Unless required by applicable law or agreed to in writing, software
12: * distributed under the License is distributed on an "AS IS" BASIS,
13: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14: * See the License for the specific language governing permissions and
15: * limitations under the License.
16: */
17:
18: package org.apache.coyote;
19:
20: import java.util.Locale;
21:
22: /**
23: * Constants.
24: *
25: * @author Remy Maucherat
26: */
27: public final class Constants {
28:
29: // -------------------------------------------------------------- Constants
30:
31: public static final String DEFAULT_CHARACTER_ENCODING = "ISO-8859-1";
32:
33: public static final String LOCALE_DEFAULT = "en";
34:
35: public static final Locale DEFAULT_LOCALE = new Locale(
36: LOCALE_DEFAULT, "");
37:
38: public static final int MAX_NOTES = 32;
39:
40: // Request states
41: public static final int STAGE_NEW = 0;
42: public static final int STAGE_PARSE = 1;
43: public static final int STAGE_PREPARE = 2;
44: public static final int STAGE_SERVICE = 3;
45: public static final int STAGE_ENDINPUT = 4;
46: public static final int STAGE_ENDOUTPUT = 5;
47: public static final int STAGE_KEEPALIVE = 6;
48: public static final int STAGE_ENDED = 7;
49:
50: /**
51: * Has security been turned on?
52: */
53: public static final boolean IS_SECURITY_ENABLED = (System
54: .getSecurityManager() != null);
55:
56: }
|