Package org.netbeans.modules.php.api.editor

Examples of org.netbeans.modules.php.api.editor.PhpBaseElement


    }

    @Override
    public boolean goToView() {
        EditorSupport editorSupport = Lookup.getDefault().lookup(EditorSupport.class);
        PhpBaseElement phpElement = editorSupport.getElement(controller, offset);
        if (phpElement == null) {
            return false;
        }
        FileObject view = CakePhpUtils.getView(controller, phpElement);
        if (view != null) {
View Full Code Here


    }

    @Override
    public boolean goToView() {
        EditorSupport editorSupport = Lookup.getDefault().lookup(EditorSupport.class);
        PhpBaseElement element = editorSupport.getElement(controller, offset);
        if (element instanceof PhpClass.Method) {

            // get view file
            PhpClass.Method method = (PhpClass.Method) element;
            String actionId = YiiUtils.getViewName(method);
View Full Code Here

        }

        // get element for caret positon
        int caretPosition = editor.getCaretPosition();
        EditorSupport editorSupport = Lookup.getDefault().lookup(EditorSupport.class);
        PhpBaseElement element = editorSupport.getElement(controller, caretPosition);

        // get actionId, controllerId
        final String actionId = getActionId(element);
        final String controllerId = getControllerId(controller);
        if (StringUtils.isEmpty(actionId) || StringUtils.isEmpty(controllerId)) {
View Full Code Here

  }

  @Override
  public boolean goToView() {
    EditorSupport editorSupport = Lookup.getDefault().lookup(EditorSupport.class);
        PhpBaseElement phpElement = editorSupport.getElement(fo, offset);
    if (phpElement == null) {
            return false;
        }
        FileObject view = EditorUtils.getView(fo, phpElement);
        if (view != null) {
View Full Code Here

        // FIXME exception might be occurred
        // if user run action at outside php class.
        // e.g. document area.
        //
        if (currentCaretPosition > startClassOffset) {
            PhpBaseElement phpElement = editorSupport.getElement(targetFile, currentCaretPosition);
            if (phpElement != null && phpElement instanceof PhpClass.Method) {
                PhpClass.Method method = (PhpClass.Method) phpElement;
                actionName = method.getName();
            }
        }
View Full Code Here

TOP

Related Classes of org.netbeans.modules.php.api.editor.PhpBaseElement

Copyright © 2018 www.massapicom. 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.