Package com.yiistorm

Source Code of com.yiistorm.YiiApplicationReferenceContributor

package com.yiistorm;

import com.intellij.psi.PsiReferenceContributor;
import com.intellij.psi.PsiReferenceRegistrar;
import com.jetbrains.php.lang.parser.PhpElementTypes;
import com.jetbrains.php.lang.patterns.PhpPatterns;
import com.yiistorm.elements.ParameterReference;
import com.yiistorm.elements.PhpStringLiteralExpressionReference;

/**
* Created with IntelliJ IDEA.
* User: mazx
* Date: 10.10.13
* Time: 8:46
* To change this template use File | Settings | File Templates.
*/
public class YiiApplicationReferenceContributor extends PsiReferenceContributor {

    @Override
    public void registerReferenceProviders(PsiReferenceRegistrar psiReferenceRegistrar) {

        psiReferenceRegistrar.registerReferenceProvider(PhpPatterns.psiElement(PhpElementTypes.PARAMETER),
                new PhpStringLiteralExpressionReference(ParameterReference.class)
                        .addCall("Yii", "getParameter")
        );


    }

}
TOP

Related Classes of com.yiistorm.YiiApplicationReferenceContributor

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.