diff options
Diffstat (limited to 'platform/indexing-api/src/com/intellij/lang')
3 files changed, 24 insertions, 2 deletions
diff --git a/platform/indexing-api/src/com/intellij/lang/cacheBuilder/DefaultWordsScanner.java b/platform/indexing-api/src/com/intellij/lang/cacheBuilder/DefaultWordsScanner.java index c4a306286708..824202fd0807 100644 --- a/platform/indexing-api/src/com/intellij/lang/cacheBuilder/DefaultWordsScanner.java +++ b/platform/indexing-api/src/com/intellij/lang/cacheBuilder/DefaultWordsScanner.java @@ -27,7 +27,7 @@ import org.jetbrains.annotations.NotNull; * @author max */ -public class DefaultWordsScanner implements WordsScanner { +public class DefaultWordsScanner extends VersionedWordsScanner { private final Lexer myLexer; private final TokenSet myIdentifierTokenSet; private final TokenSet myCommentTokenSet; diff --git a/platform/indexing-api/src/com/intellij/lang/cacheBuilder/SimpleWordsScanner.java b/platform/indexing-api/src/com/intellij/lang/cacheBuilder/SimpleWordsScanner.java index 6273654982a9..069c8643ae19 100644 --- a/platform/indexing-api/src/com/intellij/lang/cacheBuilder/SimpleWordsScanner.java +++ b/platform/indexing-api/src/com/intellij/lang/cacheBuilder/SimpleWordsScanner.java @@ -25,7 +25,7 @@ import com.intellij.util.text.CharArrayUtil; * * @author max */ -public class SimpleWordsScanner implements WordsScanner { +public class SimpleWordsScanner extends VersionedWordsScanner { public void processWords(CharSequence fileText, Processor<WordOccurrence> processor) { int index = 0; WordOccurrence occurrence = null; diff --git a/platform/indexing-api/src/com/intellij/lang/cacheBuilder/VersionedWordsScanner.java b/platform/indexing-api/src/com/intellij/lang/cacheBuilder/VersionedWordsScanner.java new file mode 100644 index 000000000000..f8d27825d14e --- /dev/null +++ b/platform/indexing-api/src/com/intellij/lang/cacheBuilder/VersionedWordsScanner.java @@ -0,0 +1,22 @@ +/* + * Copyright 2000-2014 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.intellij.lang.cacheBuilder; + +public abstract class VersionedWordsScanner implements WordsScanner { + public int getVersion() { + return 1; + } +} |