|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.python.core.PyObject
org.python.core.PyInteger
org.python.core.PyBoolean
public class PyBoolean
The builtin python bool. It would be nice if it didn't extend PyInteger, but too hard to avoid pre-Python 2.2 semantics here.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.python.core.PyObject |
---|
PyObject.ConversionException |
Field Summary | |
---|---|
static PyType |
TYPE
|
Fields inherited from class org.python.core.PyInteger |
---|
MAX_INT, maxInt, MIN_INT, minInt |
Constructor Summary | |
---|---|
PyBoolean(boolean value)
|
Method Summary | |
---|---|
PyObject |
__abs__()
Equivalent to the standard Python __abs__ method. |
PyObject |
__and__(PyObject right)
Equivalent to the standard Python __and__ method |
PyObject |
__neg__()
Equivalent to the standard Python __neg__ method. |
boolean |
__nonzero__()
Equivalent to the standard Python __nonzero__ method. |
PyObject |
__or__(PyObject right)
Equivalent to the standard Python __or__ method |
PyObject |
__pos__()
Equivalent to the standard Python __pos__ method. |
Object |
__tojava__(Class<?> c)
Equivalent to the Jython __tojava__ method. |
PyObject |
__xor__(PyObject right)
Equivalent to the standard Python __xor__ method |
static PyObject |
bool_new(PyNewWrapper new_,
boolean init,
PyType subtype,
PyObject[] args,
String[] keywords)
|
boolean |
getBooleanValue()
|
int |
getValue()
|
int |
hashCode()
|
String |
toString()
|
Methods inherited from class org.python.core.PyInteger |
---|
__add__, __cmp__, __coerce_ex__, __complex__, __div__, __divmod__, __float__, __floordiv__, __getnewargs__, __hex__, __index__, __int__, __invert__, __long__, __lshift__, __mod__, __mul__, __oct__, __pow__, __radd__, __rdiv__, __rfloordiv__, __rmod__, __rmul__, __rpow__, __rshift__, __rsub__, __rtruediv__, __sub__, __truediv__, asIndex, asInt, asInt, asLong, asLong, int_new, isIndex, isMappingType, isNumberType, isSequenceType |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final PyType TYPE
Constructor Detail |
---|
public PyBoolean(boolean value)
Method Detail |
---|
public boolean getBooleanValue()
public int getValue()
getValue
in class PyInteger
public static PyObject bool_new(PyNewWrapper new_, boolean init, PyType subtype, PyObject[] args, String[] keywords)
public String toString()
toString
in class PyInteger
public int hashCode()
hashCode
in class PyInteger
public boolean __nonzero__()
PyObject
PyObject
is considered true.
__nonzero__
in class PyInteger
public Object __tojava__(Class<?> c)
PyObject
Py.NoConversion
if this PyObject
can not be converted to the
desired Java class.
__tojava__
in class PyInteger
c
- the Class to convert this PyObject
to.public PyObject __and__(PyObject right)
PyObject
__and__
in class PyInteger
right
- the object to perform this binary operation with
(the right-hand operand).
public PyObject __xor__(PyObject right)
PyObject
__xor__
in class PyInteger
right
- the object to perform this binary operation with
(the right-hand operand).
public PyObject __or__(PyObject right)
PyObject
__or__
in class PyInteger
right
- the object to perform this binary operation with
(the right-hand operand).
public PyObject __neg__()
PyObject
__neg__
in class PyInteger
public PyObject __pos__()
PyObject
__pos__
in class PyInteger
public PyObject __abs__()
PyObject
__abs__
in class PyInteger
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |