Package ai.timefold.jpyinterpreter.types
Class PythonKnownFunctionType
java.lang.Object
ai.timefold.jpyinterpreter.types.PythonLikeType
ai.timefold.jpyinterpreter.types.PythonKnownFunctionType
- All Implemented Interfaces:
PythonLikeObject,PythonLikeFunction
-
Field Summary
Fields inherited from class ai.timefold.jpyinterpreter.types.PythonLikeType
__dir__, MRO -
Constructor Summary
ConstructorsConstructorDescriptionPythonKnownFunctionType(String methodName, List<PythonFunctionSignature> overloadFunctionSignatureList) -
Method Summary
Modifier and TypeMethodDescriptionReturn a generic version ofPythonLikeObject.$getType().$getType()Returns the type describing the objectgetFunctionForParameters(int positionalItemCount, List<String> keywordNames, List<PythonLikeType> callStackTypeList) getFunctionForParameters(PythonLikeType... parameters) booleanbooleanMethods inherited from class ai.timefold.jpyinterpreter.types.PythonLikeType
$call, $deleteAttribute, $getAttributeOrNull, $method$__getattribute__, $method$__str__, $setAttribute, addBinaryMethod, addBinaryMethod, addConstructor, addInstanceField, addLeftBinaryMethod, addLeftBinaryMethod, addMethod, addMethod, addRightBinaryMethod, addRightBinaryMethod, addTernaryMethod, addTernaryMethod, addUnaryMethod, addUnaryMethod, clearMethod, equals, getConstructorType, getDefiningTypeOrNull, getDepth, getInstanceFieldDescriptor, getJavaClass, getJavaClassOrDefault, getJavaObjectWrapperType, getJavaTypeDescriptor, getJavaTypeInternalName, getKnownMethods, getKnownMethodsDefinedByClass, getMethodKind, getMethodType, getParentList, getTypeForNewClass, getTypeName, hashCode, initializeNewType, isInstance, isSubclassOf, loadMethod, registerBaseType, registerTypeType, setConstructor, toString, unifyWithMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface ai.timefold.jpyinterpreter.PythonLikeObject
$getAttributeOrError, $method$__delattr__, $method$__eq__, $method$__format__, $method$__format__, $method$__hash__, $method$__ne__, $method$__repr__, $method$__setattr__
-
Constructor Details
-
PythonKnownFunctionType
public PythonKnownFunctionType(String methodName, List<PythonFunctionSignature> overloadFunctionSignatureList)
-
-
Method Details
-
getOverloadFunctionSignatureList
-
isStaticMethod
public boolean isStaticMethod() -
isClassMethod
public boolean isClassMethod() -
$getType
Description copied from interface:PythonLikeObjectReturns the type describing the object- Specified by:
$getTypein interfacePythonLikeFunction- Specified by:
$getTypein interfacePythonLikeObject- Overrides:
$getTypein classPythonLikeType- Returns:
- the type describing the object
-
$getGenericType
Description copied from interface:PythonLikeObjectReturn a generic version ofPythonLikeObject.$getType(). This is used in bytecode generation and not at runtime. For example, for a list of integers, this return list[int], while getType returns list. Both methods are needed so type([1,2,3]) is type(['a', 'b', 'c']) return True.- Specified by:
$getGenericTypein interfacePythonLikeObject- Overrides:
$getGenericTypein classPythonLikeType- Returns:
- the generic version of this object's type. Must not be used in identity checks.
-
getDefaultFunctionSignature
-
getFunctionForParameters
-
getFunctionForParameters
public Optional<PythonFunctionSignature> getFunctionForParameters(int positionalItemCount, List<String> keywordNames, List<PythonLikeType> callStackTypeList)
-