OLD | NEW |
(Empty) | |
| 1 /* |
| 2 * Copyright (c) 2014, the Dart project authors. |
| 3 * |
| 4 * Licensed under the Eclipse Public License v1.0 (the "License"); you may not u
se this file except |
| 5 * in compliance with the License. You may obtain a copy of the License at |
| 6 * |
| 7 * http://www.eclipse.org/legal/epl-v10.html |
| 8 * |
| 9 * Unless required by applicable law or agreed to in writing, software distribut
ed under the License |
| 10 * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY K
IND, either express |
| 11 * or implied. See the License for the specific language governing permissions a
nd limitations under |
| 12 * the License. |
| 13 */ |
| 14 |
| 15 package com.google.dart.engine.internal.index.file; |
| 16 |
| 17 import com.google.dart.engine.context.AnalysisContext; |
| 18 |
| 19 /** |
| 20 * A manager for {@link IndexNode}s. |
| 21 * |
| 22 * @coverage dart.engine.index |
| 23 */ |
| 24 public interface NodeManager { |
| 25 /** |
| 26 * Returns number of locations in all nodes. |
| 27 */ |
| 28 public int getLocationCount(); |
| 29 |
| 30 /** |
| 31 * Removes all nodes. |
| 32 */ |
| 33 void clear(); |
| 34 |
| 35 /** |
| 36 * Returns the shared {@link ContextCodec} instance. |
| 37 */ |
| 38 ContextCodec getContextCodec(); |
| 39 |
| 40 /** |
| 41 * Returns the shared {@link ElementCodec} instance. |
| 42 */ |
| 43 ElementCodec getElementCodec(); |
| 44 |
| 45 /** |
| 46 * Returns the {@link IndexNode} with the given name, {@code null} if not foun
d. |
| 47 */ |
| 48 IndexNode getNode(String name); |
| 49 |
| 50 /** |
| 51 * Returns the shared {@link StringCodec} instance. |
| 52 */ |
| 53 StringCodec getStringCodec(); |
| 54 |
| 55 /** |
| 56 * Returns a new {@link IndexNode}. |
| 57 */ |
| 58 IndexNode newNode(AnalysisContext context); |
| 59 |
| 60 /** |
| 61 * Associates the given {@link IndexNode} with the given name. |
| 62 */ |
| 63 void putNode(String name, IndexNode node); |
| 64 |
| 65 /** |
| 66 * Removes the {@link IndexNode} with the given name. |
| 67 */ |
| 68 void removeNode(String name); |
| 69 } |
OLD | NEW |