mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Use object instead of pair for describing function type parameters
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
package com.jetbrains.python.psi.types;
|
||||
|
||||
import com.jetbrains.python.psi.PyParameter;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
/**
|
||||
* @author vlan
|
||||
*/
|
||||
public interface PyCallableParameter {
|
||||
@Nullable
|
||||
String getName();
|
||||
|
||||
@Nullable
|
||||
PyType getType();
|
||||
|
||||
@Nullable
|
||||
PyParameter getParameter();
|
||||
}
|
||||
@@ -1,6 +1,5 @@
|
||||
package com.jetbrains.python.psi.types;
|
||||
|
||||
import com.intellij.openapi.util.Pair;
|
||||
import com.jetbrains.python.psi.PyQualifiedExpression;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
@@ -32,8 +31,8 @@ public interface PyCallableType extends PyType {
|
||||
/**
|
||||
* Returns the list of parameter types.
|
||||
*
|
||||
* @return list of (name, type) pairs or null if not applicable. Name and type in pair may be null.
|
||||
* @return list of parameter info null if not applicable.
|
||||
*/
|
||||
@Nullable
|
||||
List<Pair<String, PyType>> getParameters(@NotNull TypeEvalContext context);
|
||||
List<PyCallableParameter> getParameters(@NotNull TypeEvalContext context);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user