blob: e12c4c4c073609f6d542f813bbc44785252a7db3 [file] [log] [blame]
nitind958d79a2004-11-23 19:23:00 +00001/*******************************************************************************
2 * Copyright (c) 2004 IBM Corporation and others.
3 * All rights reserved. This program and the accompanying materials
4 * are made available under the terms of the Eclipse Public License v1.0
5 * which accompanies this distribution, and is available at
6 * http://www.eclipse.org/legal/epl-v10.html
7 *
8 * Contributors:
9 * IBM Corporation - initial API and implementation
10 *******************************************************************************/
david_williams56777022005-04-11 06:21:55 +000011package org.eclipse.wst.html.core.internal.contentmodel.chtml;
nitind958d79a2004-11-23 19:23:00 +000012
13
14
15import java.util.Arrays;
16import java.util.Iterator;
17
18/**
19 * DT.
20 */
21final class HedDT extends HedInlineContainer {
22
23 private static String[] terminators = {CHTMLNamespace.ElementName.DT, CHTMLNamespace.ElementName.DD};
24
25 /**
26 */
27 public HedDT(ElementCollection collection) {
28 super(CHTMLNamespace.ElementName.DT, collection);
29 correctionType = CORRECT_EMPTY;
30 layoutType = LAYOUT_BLOCK;
31 omitType = OMIT_END_DEFAULT;
32 }
33
34 /**
35 * %attrs;
36 */
37 protected void createAttributeDeclarations() {
38 if (attributes != null)
39 return; // already created.
40 if (attributeCollection == null)
41 return; // fatal
42
43 attributes = new CMNamedNodeMapImpl();
44
45 // %attrs;
46 attributeCollection.getAttrs(attributes);
47 }
48
49 /**
50 * DT has terminators.
51 * @return java.util.Iterator
52 */
53 protected Iterator getTerminators() {
54 return Arrays.asList(terminators).iterator();
55 }
56}