Skip to content

Commit

Permalink
Fix index service
Browse files Browse the repository at this point in the history
  • Loading branch information
oowekyala committed May 25, 2019
1 parent fb40a58 commit 2daa2a9
Show file tree
Hide file tree
Showing 7 changed files with 71 additions and 76 deletions.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
// This is a generated file. Not intended for manual editing.
package com.github.oowekyala.ijcc.lang.psi

import com.github.oowekyala.ijcc.lang.psi.stubs.JccScopedExpansionUnitStub
import com.intellij.psi.StubBasedPsiElement

interface JccScopedExpansionUnit
: JccIdentifierOwner,
JccExpansionUnit,
JjtNodeClassOwner,
StubBasedPsiElement<JccScopedExpansionUnitStub> {

val expansionUnit: JccExpansionUnit

override val jjtreeNodeDescriptor: JccJjtreeNodeDescriptor

override fun getNameIdentifier(): JccIdentifier?

}

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
// This is a generated file. Not intended for manual editing.
package com.github.oowekyala.ijcc.lang.psi.impl

import com.github.oowekyala.ijcc.lang.psi.*
import com.github.oowekyala.ijcc.lang.psi.stubs.JccScopedExpansionUnitStub
import com.intellij.lang.ASTNode
import com.intellij.psi.PsiElementVisitor
import com.intellij.psi.stubs.IStubElementType
import com.intellij.psi.util.PsiTreeUtil

class JccScopedExpansionUnitImpl : JjtNodeClassOwnerImpl<JccScopedExpansionUnitStub>, JccScopedExpansionUnit {

override val jjtreeNodeDescriptor: JccJjtreeNodeDescriptor
get() = notNullChild<JccJjtreeNodeDescriptor>(
PsiTreeUtil.getChildOfType(
this,
JccJjtreeNodeDescriptor::class.java
)
)

constructor(node: ASTNode) : super(node)

constructor(stub: JccScopedExpansionUnitStub, stubType: IStubElementType<JccScopedExpansionUnitStub, *>) : super(stub, stubType)

fun accept(visitor: JccVisitor) {
visitor.visitScopedExpansionUnit(this)
}

override fun accept(visitor: PsiElementVisitor) {
if (visitor is JccVisitor)
accept(visitor)
else
super.accept(visitor)
}

override val expansionUnit: JccExpansionUnit
get() = notNullChild<JccExpansionUnit>(PsiTreeUtil.getChildOfType(this, JccExpansionUnit::class.java))

override fun getNameIdentifier(): JccIdentifier? {
val p1 = jjtreeNodeDescriptor
return p1.nameIdentifier
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ import com.intellij.util.io.KeyDescriptor


/**
* Indexes the qualified name of the parser class of a grammar file,
* in order to provide links from the generated parser to the grammar.
*
* @author Clément Fournier
* @since 1.2
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ import com.intellij.psi.stubs.StringStubIndexExtension
import com.intellij.psi.stubs.StubIndexKey

/**
* Indexes the node class owners of a grammar by qname, to provide
* links from the node classes to the productions.
*
* @author Clément Fournier
* @since 1.2
*/
Expand All @@ -17,4 +20,4 @@ object JjtreeQNameStubIndex : StringStubIndexExtension<JjtNodeClassOwner>() {

override fun getVersion(): Int = 1

}
}
2 changes: 1 addition & 1 deletion idea/src/main/resources/META-INF/plugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@

<applicationService
serviceInterface="com.github.oowekyala.ijcc.lang.psi.stubs.StubIndexService"
implementationClass="com.github.oowekyala.ijcc.lang.psi.stubs.indices.IdeStubService"/>
serviceImplementation="com.github.oowekyala.ijcc.lang.psi.stubs.indices.IdeStubService"/>

<!-- GUTTER -->

Expand Down

0 comments on commit 2daa2a9

Please sign in to comment.