Class NumericObject
A numeric object (int or float). Includes those occurring in the source as a literal or in a builtin module as a value.
Import path
import python
Direct supertypes
Indirect supertypes
Predicates
booleanValue | Gets the Boolean value that this object would evaluate to in a Boolean context, such as |
floatValue | Gets the value of this object if it is a constant float |
intValue | Gets the value of this object if it is a constant integer and it fits in a QL int |
repr | Gets the string representation of this object, equivalent to calling repr() in Python |
Inherited predicates
asBuiltin | INTERNAL – Do not use | from Object |
getAnInferredType | Gets an inferred type for this object, without using inter-procedural analysis. WARNING: The lack of context makes this less accurate than f.refersTo(this, result, _) for a control flow node ‘f’ | from Object |
getOrigin | Gets the point in the source code from which this object “originates”. | from Object |
hasLocationInfo | Holds if this element is at the specified location. The location spans column | from Object |
hasLongName | Holds if this object can be referred to by | from Object |
isBuiltin | Whether this is a builtin object. A builtin object is one defined by the implementation, such as the integer 4 or by a native extension, such as a NumPy array class. | from Object |
isC | Retained for backwards compatibility. See Object.isBuiltin() | from Object |
maybe | from Object | |
notClass | from Object | |
overrides | Whether this overrides o. In this context, “overrides” means that this object is a named attribute of a some class C and | from Object |
simpleClass | Gets the class of this object for simple cases, namely constants, functions, comprehensions and built-in objects. | from Object |
toString | Gets a textual representation of this element. | from Object |