Package org.python.core
Class __builtin__
- java.lang.Object
-
- org.python.core.__builtin__
-
public class __builtin__ extends java.lang.Object
The builtin module. All builtin functions are defined here
-
-
Field Summary
Fields Modifier and Type Field Description static PyString
__doc__zip
-
Constructor Summary
Constructors Constructor Description __builtin__()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static PyObject
__import__(java.lang.String name)
static PyObject
__import__(java.lang.String name, PyObject globals)
static PyObject
__import__(java.lang.String name, PyObject globals, PyObject locals)
static PyObject
__import__(java.lang.String name, PyObject globals, PyObject locals, PyObject fromlist)
static PyObject
__import__(java.lang.String name, PyObject globals, PyObject locals, PyObject fromlist, int level)
static PyObject
abs(PyObject o)
static PyObject
apply(PyObject o)
static PyObject
apply(PyObject o, PyObject args)
static PyObject
apply(PyObject o, PyObject args, PyDictionary kws)
static boolean
callable(PyObject obj)
static char
chr(int i)
static int
cmp(PyObject x, PyObject y)
static PyTuple
coerce(PyObject o1, PyObject o2)
static void
delattr(PyObject obj, PyObject name)
static PyObject
dir()
static PyObject
dir(PyObject o)
static PyObject
divmod(PyObject x, PyObject y)
static PyObject
eval(PyObject o)
static PyObject
eval(PyObject o, PyObject globals)
static PyObject
eval(PyObject o, PyObject globals, PyObject locals)
static void
execfile(java.lang.String name)
static void
execfile(java.lang.String name, PyObject globals)
static void
execfile(java.lang.String name, PyObject globals, PyObject locals)
static void
execfile_flags(java.lang.String name, PyObject globals, PyObject locals, CompilerFlags cflags)
static void
fillWithBuiltins(PyObject dict)
static PyObject
filter(PyObject func, PyObject seq)
static PyObject
filterBaseString(PyObject func, PyBaseString seq, PyType stringType)
static PyObject
filterTuple(PyObject func, PyTuple seq)
static PyObject
getattr(PyObject obj, PyObject name)
static PyObject
getattr(PyObject obj, PyObject nameObj, PyObject def)
static PyObject
globals()
static boolean
hasattr(PyObject obj, PyObject nameObj)
static PyInteger
hash(PyObject o)
static PyString
hex(PyObject o)
static long
id(PyObject o)
static PyObject
input()
static PyObject
input(PyObject prompt)
static PyString
intern(PyObject obj)
static boolean
isinstance(PyObject obj, PyObject cls)
static boolean
issubclass(PyObject derived, PyObject cls)
static PyObject
iter(PyObject obj)
static PyObject
iter(PyObject callable, PyObject sentinel)
static int
len(PyObject obj)
static PyObject
locals()
static PyObject
map(PyObject[] argstar)
static PyString
oct(PyObject o)
static int
ord(PyObject c)
Built-in Python function ord() applicable to the string-like typesstr
,bytearray
,unicode
.static PyObject
pow(PyObject x, PyObject y)
static PyObject
pow(PyObject x, PyObject y, PyObject z)
static PyObject
range(PyObject n)
static PyObject
range(PyObject start, PyObject stop)
static PyObject
range(PyObject ilow, PyObject ihigh, PyObject istep)
static java.lang.String
raw_input()
Implementation ofraw_input()
built-in function using the console directly.static java.lang.String
raw_input(PyObject prompt)
Implementation ofraw_input(prompt)
built-in function using the console indirectly viasys.stdin
andsys.stdin
.static java.lang.String
raw_input(PyObject prompt, PyObject file)
Companion toraw_input
built-in function used when the interactive interpreter is directed to a file.static PyObject
reduce(PyObject f, PyObject l)
static PyObject
reduce(PyObject f, PyObject l, PyObject z)
static PyObject
reload(PyModule o)
static PyObject
reload(PyObject o)
static PyObject
reload(PySystemState o)
static PyString
repr(PyObject o)
static PyObject
reversed(PyObject seq)
static void
setattr(PyObject obj, PyObject name, PyObject value)
static PyObject
sum(PyObject seq)
static PyObject
sum(PyObject seq, PyObject result)
static PyType
type(PyObject o)
static int
unichr(int i)
static int
unichr(PyObject obj)
static PyObject
vars()
static PyObject
vars(PyObject o)
static PyObject
zip()
static PyObject
zip(PyObject[] argstar)
-
-
-
Field Detail
-
__doc__zip
public static PyString __doc__zip
-
-
Method Detail
-
fillWithBuiltins
public static void fillWithBuiltins(PyObject dict)
-
apply
public static PyObject apply(PyObject o, PyObject args, PyDictionary kws)
-
callable
public static boolean callable(PyObject obj)
-
unichr
public static int unichr(PyObject obj)
-
unichr
public static int unichr(int i)
-
chr
public static char chr(int i)
-
dir
public static PyObject dir()
-
execfile_flags
public static void execfile_flags(java.lang.String name, PyObject globals, PyObject locals, CompilerFlags cflags)
-
execfile
public static void execfile(java.lang.String name, PyObject globals)
-
execfile
public static void execfile(java.lang.String name)
-
filterBaseString
public static PyObject filterBaseString(PyObject func, PyBaseString seq, PyType stringType)
-
globals
public static PyObject globals()
-
id
public static long id(PyObject o)
-
input
public static PyObject input()
-
len
public static int len(PyObject obj)
-
locals
public static PyObject locals()
-
ord
public static final int ord(PyObject c) throws PyException
Built-in Python function ord() applicable to the string-like typesstr
,bytearray
,unicode
.- Parameters:
c
- string-like object of length 1- Returns:
- ordinal value of character or byte value in
- Throws:
PyException
- (TypeError) if not a string-like type
-
raw_input
public static java.lang.String raw_input(PyObject prompt, PyObject file)
Companion toraw_input
built-in function used when the interactive interpreter is directed to a file.- Parameters:
prompt
- to issue at console before readfile
- a file-like object to read from- Returns:
- line of text from the file (encoded as bytes values compatible with PyString)
-
raw_input
public static java.lang.String raw_input(PyObject prompt)
Implementation ofraw_input(prompt)
built-in function using the console indirectly viasys.stdin
andsys.stdin
.- Parameters:
prompt
- to issue at console before read- Returns:
- line of text from console (encoded as bytes values compatible with PyString)
-
raw_input
public static java.lang.String raw_input()
Implementation ofraw_input()
built-in function using the console directly.- Returns:
- line of text from console (encoded as bytes values compatible with PyString)
-
reload
public static PyObject reload(PySystemState o)
-
vars
public static PyObject vars()
-
zip
public static PyObject zip()
-
__import__
public static PyObject __import__(java.lang.String name)
-
__import__
public static PyObject __import__(java.lang.String name, PyObject globals, PyObject locals)
-
__import__
public static PyObject __import__(java.lang.String name, PyObject globals, PyObject locals, PyObject fromlist)
-
-