some PSI for template languages in python-psi-api; common superinterface for string literals in Python code and templates

This commit is contained in:
Dmitry Jemerov
2012-08-16 14:38:20 +02:00
parent 2ee455cea1
commit 0428956e2c
5 changed files with 85 additions and 3 deletions
@@ -6,9 +6,7 @@ import com.intellij.psi.PsiLanguageInjectionHost;
import java.util.List;
public interface PyStringLiteralExpression extends PyLiteralExpression, PsiLanguageInjectionHost {
String getStringValue();
public interface PyStringLiteralExpression extends PyLiteralExpression, StringLiteralExpression, PsiLanguageInjectionHost {
List<TextRange> getStringValueTextRanges();
List<ASTNode> getStringNodes();
@@ -0,0 +1,14 @@
package com.jetbrains.python.psi;
import com.intellij.openapi.util.TextRange;
import com.intellij.psi.PsiElement;
/**
* A generic string literal interface (used both in Python code and template files).
*
* @author yole
*/
public interface StringLiteralExpression extends PsiElement {
String getStringValue();
TextRange getStringValueTextRange();
}