Package org.eclipse.php.internal.core.ast.nodes

Examples of org.eclipse.php.internal.core.ast.nodes.StaticMethodInvocation


          return DEFAULT_NAME;
        }
       
        return getBasicName(func.getFunctionName().getName());
      case ASTNode.STATIC_METHOD_INVOCATION:
        StaticMethodInvocation st = (StaticMethodInvocation) node;
        return getBasicName(st.getMethod());
      case ASTNode.CLASS_INSTANCE_CREATION:
        ClassInstanceCreation ci = (ClassInstanceCreation) node;
        if (ci.getClassName() != null) {
          return getBasicName(ci.getClassName().getName());
        }
View Full Code Here


    String str = "<?php class MyClass { static function foo(){} } MyClass::foo($a); ?>";
    Program program = createAndParse(str);

    ExpressionStatement statement = (ExpressionStatement) program
        .statements().get(1);
    StaticMethodInvocation staticMethodInvocation = (StaticMethodInvocation) statement
        .getExpression();

    IMethodBinding methodBinding = staticMethodInvocation
        .resolveMethodBinding();

    Assert.assertNotNull(methodBinding);
    Assert.assertTrue(methodBinding.isConstructor() == false);
    Assert.assertTrue(methodBinding.getName().equals("foo"));
View Full Code Here

TOP

Related Classes of org.eclipse.php.internal.core.ast.nodes.StaticMethodInvocation

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.