src/share/classes/com/sun/tools/doclets/internal/toolkit/util/IndexBuilder.java

changeset 1606
ccbe7ffdd867
parent 1359
25e14ad23cef
child 2525
2eb010b6cb22
equal deleted inserted replaced
1605:94e67bed460d 1606:ccbe7ffdd867
1 /* 1 /*
2 * Copyright (c) 1998, 2012, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 * 4 *
5 * This code is free software; you can redistribute it and/or modify it 5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as 6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. Oracle designates this 7 * published by the Free Software Foundation. Oracle designates this
60 60
61 /** 61 /**
62 * Build this Index only for classes? 62 * Build this Index only for classes?
63 */ 63 */
64 private boolean classesOnly; 64 private boolean classesOnly;
65
66 /**
67 * Indicates javafx mode.
68 */
69 private boolean javafx;
65 70
66 // make ProgramElementDoc[] when new toArray is available 71 // make ProgramElementDoc[] when new toArray is available
67 protected final Object[] elements; 72 protected final Object[] elements;
68 73
69 /** 74 /**
113 } else { 118 } else {
114 configuration.message.notice("doclet.Building_Index"); 119 configuration.message.notice("doclet.Building_Index");
115 } 120 }
116 this.noDeprecated = noDeprecated; 121 this.noDeprecated = noDeprecated;
117 this.classesOnly = classesOnly; 122 this.classesOnly = classesOnly;
123 this.javafx = configuration.javafx;
118 buildIndexMap(configuration.root); 124 buildIndexMap(configuration.root);
119 Set<Character> set = indexmap.keySet(); 125 Set<Character> set = indexmap.keySet();
120 elements = set.toArray(); 126 elements = set.toArray();
121 Arrays.sort(elements); 127 Arrays.sort(elements);
122 } 128 }
207 213
208 /** 214 /**
209 * Should this doc element be added to the index map? 215 * Should this doc element be added to the index map?
210 */ 216 */
211 protected boolean shouldAddToIndexMap(Doc element) { 217 protected boolean shouldAddToIndexMap(Doc element) {
218 if (javafx) {
219 if (element.tags("treatAsPrivate").length > 0) {
220 return false;
221 }
222 }
223
212 if (element instanceof PackageDoc) 224 if (element instanceof PackageDoc)
213 // Do not add to index map if -nodeprecated option is set and the 225 // Do not add to index map if -nodeprecated option is set and the
214 // package is marked as deprecated. 226 // package is marked as deprecated.
215 return !(noDeprecated && Util.isDeprecated(element)); 227 return !(noDeprecated && Util.isDeprecated(element));
216 else 228 else

mercurial