Skip to content

Commit 7262819

Browse files
committed
chore: rename to console
1 parent a5a7a30 commit 7262819

File tree

3 files changed

+9
-8
lines changed

3 files changed

+9
-8
lines changed

src/main/kotlin/com/github/tempest/framework/router/AbstractIndex.kt renamed to src/main/kotlin/com/github/tempest/framework/common/index/AbstractIndex.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package com.github.tempest.framework.router
1+
package com.github.tempest.framework.common.index
22

33
import com.intellij.util.indexing.DataIndexer
44
import com.intellij.util.indexing.FileBasedIndex
@@ -19,4 +19,4 @@ abstract class AbstractIndex<T : Any> : FileBasedIndexExtension<String, T>() {
1919
override fun getKeyDescriptor() = EnumeratorStringDescriptor.INSTANCE
2020

2121
override fun getVersion() = 1
22-
}
22+
}

src/main/kotlin/com/github/tempest/framework/router/RoutesIndex.kt renamed to src/main/kotlin/com/github/tempest/framework/console/index/ConsoleCommandsIndex.kt

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
1-
package com.github.tempest.framework.router
1+
package com.github.tempest.framework.console.index
22

33
import com.github.tempest.framework.TempestFrameworkClasses
44
import com.github.tempest.framework.TempestFrameworkUtil
5+
import com.github.tempest.framework.common.index.AbstractIndex
56
import com.intellij.openapi.util.text.StringUtil
67
import com.intellij.psi.util.PsiTreeUtil
78
import com.intellij.util.indexing.DataIndexer
@@ -12,11 +13,11 @@ import com.intellij.util.io.EnumeratorStringDescriptor
1213
import com.jetbrains.php.lang.PhpFileType
1314
import com.jetbrains.php.lang.psi.elements.PhpAttribute
1415

15-
private typealias RouteType = String
16+
private typealias ConsoleCommandsIndexType = String
1617

17-
class RoutesIndex : AbstractIndex<RouteType>() {
18+
class ConsoleCommandsIndex : AbstractIndex<ConsoleCommandsIndexType>() {
1819
companion object {
19-
val key = ID.create<String, RouteType>("Tempest.Routes")
20+
val key = ID.create<String, ConsoleCommandsIndexType>("Tempest.ConsoleCommands")
2021
}
2122

2223
override fun getVersion() = 1
@@ -30,7 +31,7 @@ class RoutesIndex : AbstractIndex<RouteType>() {
3031
!it.name.endsWith(TempestFrameworkUtil.TEMPLATE_SUFFIX)
3132
}
3233

33-
override fun getIndexer() = DataIndexer<String, RouteType, FileContent> { inputData ->
34+
override fun getIndexer() = DataIndexer<String, ConsoleCommandsIndexType, FileContent> { inputData ->
3435
inputData
3536
.psiFile
3637
.let { PsiTreeUtil.findChildrenOfType(it, PhpAttribute::class.java) }

src/main/resources/META-INF/plugin.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
implementationClass="com.github.tempest.framework.views.TempestComponentsInspectionSuppressor"/>
2929

3030
<fileBasedIndex
31-
implementation="com.github.tempest.framework.router.RoutesIndex" />
31+
implementation="com.github.tempest.framework.console.index.ConsoleCommandsIndex" />
3232
</extensions>
3333
<extensions defaultExtensionNs="com.jetbrains.php">
3434

0 commit comments

Comments
 (0)