1 /*
2 * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
3 */
4 /*
5 * Licensed to the Apache Software Foundation (ASF) under one or more
6 * contributor license agreements. See the NOTICE file distributed with
7 * this work for additional information regarding copyright ownership.
8 * The ASF licenses this file to You under the Apache License, Version 2.0
9 * (the "License"); you may not use this file except in compliance with
10 * the License. You may obtain a copy of the License at
11 *
12 * http://www.apache.org/licenses/LICENSE-2.0
13 *
14 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS,
16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * See the License for the specific language governing permissions and
18 * limitations under the License.
19 */
20
21 // Aug 21, 2000:
22 // Fixed bug in isElement and made HTMLdtd public.
34 import java.util.Map;
35
36
37 /**
38 * Utility class for accessing information specific to HTML documents.
39 * The HTML DTD is expressed as three utility function groups. Two methods
40 * allow for checking whether an element requires an open tag on printing
41 * ({@link #isEmptyTag}) or on parsing ({@link #isOptionalClosing}).
42 * <P>
43 * Two other methods translate character references from name to value and
44 * from value to name. A small entities resource is loaded into memory the
45 * first time any of these methods is called for fast and efficient access.
46 *
47 * @author <a href="mailto:arkin@intalio.com">Assaf Arkin</a>
48 *
49 * @deprecated As of JDK 9, Xerces 2.9.0, Xerces DOM L3 Serializer implementation
50 * is replaced by that of Xalan. Main class
51 * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced
52 * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}.
53 */
54 public final class HTMLdtd
55 {
56
57 /**
58 * Public identifier for HTML 4.01 (Strict) document type.
59 */
60 public static final String HTMLPublicId = "-//W3C//DTD HTML 4.01//EN";
61
62 /**
63 * System identifier for HTML 4.01 (Strict) document type.
64 */
65 public static final String HTMLSystemId =
66 "http://www.w3.org/TR/html4/strict.dtd";
67
68 /**
69 * Public identifier for XHTML 1.0 (Strict) document type.
70 */
71 public static final String XHTMLPublicId =
72 "-//W3C//DTD XHTML 1.0 Strict//EN";
73
|
1 /*
2 * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved.
3 */
4 /*
5 * Licensed to the Apache Software Foundation (ASF) under one or more
6 * contributor license agreements. See the NOTICE file distributed with
7 * this work for additional information regarding copyright ownership.
8 * The ASF licenses this file to You under the Apache License, Version 2.0
9 * (the "License"); you may not use this file except in compliance with
10 * the License. You may obtain a copy of the License at
11 *
12 * http://www.apache.org/licenses/LICENSE-2.0
13 *
14 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS,
16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * See the License for the specific language governing permissions and
18 * limitations under the License.
19 */
20
21 // Aug 21, 2000:
22 // Fixed bug in isElement and made HTMLdtd public.
34 import java.util.Map;
35
36
37 /**
38 * Utility class for accessing information specific to HTML documents.
39 * The HTML DTD is expressed as three utility function groups. Two methods
40 * allow for checking whether an element requires an open tag on printing
41 * ({@link #isEmptyTag}) or on parsing ({@link #isOptionalClosing}).
42 * <P>
43 * Two other methods translate character references from name to value and
44 * from value to name. A small entities resource is loaded into memory the
45 * first time any of these methods is called for fast and efficient access.
46 *
47 * @author <a href="mailto:arkin@intalio.com">Assaf Arkin</a>
48 *
49 * @deprecated As of JDK 9, Xerces 2.9.0, Xerces DOM L3 Serializer implementation
50 * is replaced by that of Xalan. Main class
51 * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced
52 * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}.
53 */
54 @Deprecated
55 public final class HTMLdtd
56 {
57
58 /**
59 * Public identifier for HTML 4.01 (Strict) document type.
60 */
61 public static final String HTMLPublicId = "-//W3C//DTD HTML 4.01//EN";
62
63 /**
64 * System identifier for HTML 4.01 (Strict) document type.
65 */
66 public static final String HTMLSystemId =
67 "http://www.w3.org/TR/html4/strict.dtd";
68
69 /**
70 * Public identifier for XHTML 1.0 (Strict) document type.
71 */
72 public static final String XHTMLPublicId =
73 "-//W3C//DTD XHTML 1.0 Strict//EN";
74
|