本文整理汇总了Java中com.jetbrains.php.lang.psi.elements.PhpClass.getImplementedInterfaces方法的典型用法代码示例。如果您正苦于以下问题:Java PhpClass.getImplementedInterfaces方法的具体用法?Java PhpClass.getImplementedInterfaces怎么用?Java PhpClass.getImplementedInterfaces使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.jetbrains.php.lang.psi.elements.PhpClass
的用法示例。
在下文中一共展示了PhpClass.getImplementedInterfaces方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: processClass
import com.jetbrains.php.lang.psi.elements.PhpClass; //导入方法依赖的package包/类
private static void processClass(@NotNull PhpClass clazz, @NotNull Set<PhpClass> processed) {
if (clazz.isInterface()) {
throw new InvalidParameterException("Interface shall not be provided");
}
processed.add(clazz);
/* re-delegate interface handling */
for (PhpClass anInterface : clazz.getImplementedInterfaces()) {
processInterface(anInterface, processed);
}
/* handle parent class */
if (null != clazz.getSuperClass()) {
processClass(clazz.getSuperClass(), processed);
}
}
示例2: verifyPhpClass
import com.jetbrains.php.lang.psi.elements.PhpClass; //导入方法依赖的package包/类
private void verifyPhpClass(PhpClass phpClass, PsiReference reference) {
if (phpClass == null) {
return;
}
if (phpClass.getPresentableFQN().equals(MagentoTypes.OBJECT_MANAGER_TYPE)) {
registerProblem(reference);
return;
}
for (PhpClass implementedInterface : phpClass.getImplementedInterfaces()) {
if (implementedInterface.getPresentableFQN().equals(MagentoTypes.OBJECT_MANAGER_TYPE)) {
registerProblem(reference);
return;
}
}
}
示例3: isImplementationOfInterface
import com.jetbrains.php.lang.psi.elements.PhpClass; //导入方法依赖的package包/类
protected boolean isImplementationOfInterface(PhpClass phpClass, PhpClass phpInterface) {
if (phpClass == phpInterface) {
return true;
}
for (PhpClass implementedInterface : phpClass.getImplementedInterfaces()) {
if (isImplementationOfInterface(implementedInterface, phpInterface)) {
return true;
}
}
if (null == phpClass.getSuperClass()) {
return false;
}
return isImplementationOfInterface(phpClass.getSuperClass(), phpInterface);
}
示例4: processInterface
import com.jetbrains.php.lang.psi.elements.PhpClass; //导入方法依赖的package包/类
private static void processInterface(@NotNull PhpClass clazz, @NotNull Set<PhpClass> processed) {
if (!clazz.isInterface()) {
throw new InvalidParameterException("Class shall not be provided");
}
if (processed.add(clazz)) {
for (PhpClass parentInterface : clazz.getImplementedInterfaces()) {
processInterface(parentInterface, processed);
}
}
}