Package coneforest.psylla.core
Class PsyBigInteger
- java.lang.Object
-
- coneforest.psylla.core.PsyBigInteger
-
- All Implemented Interfaces:
PsyAdditive<PsyNumeric>,PsyArithmetic<PsyNumeric>,PsyAtomic,PsyBitwise<PsyBigInteger>,PsyConvertableToInteger,PsyConvertableToName,PsyConvertableToReal,PsyConvertableToString,PsyIntegral,PsyLogical<PsyBigInteger>,PsyNumeric,PsyObject,PsyRealNumeric,PsyScalar<PsyRealNumeric>
public class PsyBigInteger extends Object implements PsyBitwise<PsyBigInteger>, PsyIntegral
-
-
Field Summary
-
Fields inherited from interface coneforest.psylla.core.PsyBitwise
OPERATORS
-
-
Constructor Summary
Constructors Constructor Description PsyBigInteger(long integer)PsyBigInteger(PsyInteger oInteger)PsyBigInteger(String image)PsyBigInteger(BigInteger value)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description BigIntegerbigIntegerValue()doubledoubleValue()booleanequals(Object object)inthashCode()intintValue()longlongValue()static PsyBigIntegerparse(String image)PsyBigIntegerpsyAbs()Returns a Ψ-numericabsolute value of this object.PsyRealNumericpsyAdd(PsyRealNumeric oNumeric)PsyBigIntegerpsyAnd(PsyBigInteger oBigInteger)Returns a result of logical conjunction of this object and given object.PsyBigIntegerpsyBitShift(PsyInteger oShift)PsyBigIntegerpsyCeiling()PsyBigIntegerpsyClearBit(PsyInteger oBit)PsyIntegerpsyCmp(PsyRealNumeric oNumeric)Compares this object against given object and returns a Ψ-integerindicating the result of the comparison.PsyBigIntegerpsyFlipBit(PsyInteger oBit)PsyBigIntegerpsyFloor()PsyBigIntegerpsyIdiv(PsyIntegral oIntegral)PsyBooleanpsyIsZero()Returns a Ψ-booleanindicating whether this object represents a zero value.PsyBigIntegerpsyMod(PsyIntegral oIntegral)PsyRealNumericpsyMul(PsyRealNumeric oNumeric)PsyBigIntegerpsyNeg()Returns a Ψ-additiverepresenting the result of arithmetic negation of this object.PsyBigIntegerpsyNot()Returns a result of logical negation of this object.PsyBigIntegerpsyOr(PsyBigInteger oBigInteger)Returns a result of logical disjunction of this object and given object.PsyBigIntegerpsyRound()PsyBigIntegerpsySetBit(PsyInteger oBit)PsyBigIntegerpsySignum()Returns the signum of this object.PsyRealNumericpsySub(PsyRealNumeric oNumeric)PsyBooleanpsyTestBit(PsyInteger oBit)PsyBigIntegerpsyXor(PsyBigInteger oBigInteger)Returns a result of logical exclusive disjunction of this object and given object.StringtoSyntaxString()-
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface coneforest.psylla.core.PsyArithmetic
psyNotZero
-
Methods inherited from interface coneforest.psylla.core.PsyObject
convert, execute, invoke, psyClone, psyHashCode, psyInstanceOf, psyNe, psySyntax, psyToName, psyToString, psyType, typeName
-
Methods inherited from interface coneforest.psylla.core.PsyRealNumeric
imagValue, psyAcos, psyAdd, psyAsin, psyAtan, psyCbrt, psyCos, psyCosh, psyDiv, psyDiv, psyEq, psyExp, psyGe, psyGt, psyHypot, psyLe, psyLog, psyLt, psyMul, psyPow, psyPow, psySin, psySinh, psySqrt, psySub, psyTan, psyTanh, psyToInteger, psyToReal, realValue
-
-
-
-
Constructor Detail
-
PsyBigInteger
public PsyBigInteger(BigInteger value)
-
PsyBigInteger
public PsyBigInteger(long integer)
-
PsyBigInteger
public PsyBigInteger(PsyInteger oInteger)
-
PsyBigInteger
public PsyBigInteger(String image)
-
-
Method Detail
-
parse
public static PsyBigInteger parse(String image)
-
intValue
public int intValue()
- Specified by:
intValuein interfacePsyRealNumeric
-
longValue
public long longValue()
- Specified by:
longValuein interfacePsyRealNumeric
-
doubleValue
public double doubleValue()
- Specified by:
doubleValuein interfacePsyRealNumeric
-
bigIntegerValue
public BigInteger bigIntegerValue()
- Specified by:
bigIntegerValuein interfacePsyIntegral
-
psyBitShift
public PsyBigInteger psyBitShift(PsyInteger oShift)
- Specified by:
psyBitShiftin interfacePsyBitwise<PsyBigInteger>
-
psyTestBit
public PsyBoolean psyTestBit(PsyInteger oBit)
- Specified by:
psyTestBitin interfacePsyBitwise<PsyBigInteger>
-
psySetBit
public PsyBigInteger psySetBit(PsyInteger oBit)
- Specified by:
psySetBitin interfacePsyBitwise<PsyBigInteger>
-
psyFlipBit
public PsyBigInteger psyFlipBit(PsyInteger oBit)
- Specified by:
psyFlipBitin interfacePsyBitwise<PsyBigInteger>
-
psyClearBit
public PsyBigInteger psyClearBit(PsyInteger oBit)
- Specified by:
psyClearBitin interfacePsyBitwise<PsyBigInteger>
-
psyOr
public PsyBigInteger psyOr(PsyBigInteger oBigInteger)
Description copied from interface:PsyLogicalReturns a result of logical disjunction of this object and given object.- Specified by:
psyOrin interfacePsyLogical<PsyBigInteger>- Parameters:
oBigInteger- given object.- Returns:
- a result.
-
psyAnd
public PsyBigInteger psyAnd(PsyBigInteger oBigInteger)
Description copied from interface:PsyLogicalReturns a result of logical conjunction of this object and given object.- Specified by:
psyAndin interfacePsyLogical<PsyBigInteger>- Parameters:
oBigInteger- given object.- Returns:
- a result.
-
psyXor
public PsyBigInteger psyXor(PsyBigInteger oBigInteger)
Description copied from interface:PsyLogicalReturns a result of logical exclusive disjunction of this object and given object.- Specified by:
psyXorin interfacePsyLogical<PsyBigInteger>- Parameters:
oBigInteger- given object.- Returns:
- a result.
-
psyNot
public PsyBigInteger psyNot()
Description copied from interface:PsyLogicalReturns a result of logical negation of this object.- Specified by:
psyNotin interfacePsyLogical<PsyBigInteger>- Returns:
- a result.
-
psyCeiling
public PsyBigInteger psyCeiling()
- Specified by:
psyCeilingin interfacePsyRealNumeric
-
psyFloor
public PsyBigInteger psyFloor()
- Specified by:
psyFloorin interfacePsyRealNumeric
-
psyRound
public PsyBigInteger psyRound()
- Specified by:
psyRoundin interfacePsyRealNumeric
-
psyAbs
public PsyBigInteger psyAbs()
Description copied from interface:PsyNumericReturns a Ψ-numericabsolute value of this object.- Specified by:
psyAbsin interfacePsyNumeric- Specified by:
psyAbsin interfacePsyRealNumeric- Returns:
- a Ψ-
numericabsolute value.
-
psyIdiv
public PsyBigInteger psyIdiv(PsyIntegral oIntegral) throws PsyException
- Specified by:
psyIdivin interfacePsyIntegral- Throws:
PsyException
-
psyMod
public PsyBigInteger psyMod(PsyIntegral oIntegral) throws PsyException
- Specified by:
psyModin interfacePsyIntegral- Throws:
PsyException
-
psyMul
public PsyRealNumeric psyMul(PsyRealNumeric oNumeric)
- Specified by:
psyMulin interfacePsyRealNumeric
-
psySub
public PsyRealNumeric psySub(PsyRealNumeric oNumeric)
- Specified by:
psySubin interfacePsyRealNumeric
-
psyAdd
public PsyRealNumeric psyAdd(PsyRealNumeric oNumeric)
- Specified by:
psyAddin interfacePsyRealNumeric
-
psyNeg
public PsyBigInteger psyNeg()
Description copied from interface:PsyAdditiveReturns a Ψ-additiverepresenting the result of arithmetic negation of this object.- Specified by:
psyNegin interfacePsyAdditive<PsyNumeric>- Specified by:
psyNegin interfacePsyRealNumeric- Returns:
- a negation.
-
psyIsZero
public PsyBoolean psyIsZero()
Description copied from interface:PsyArithmeticReturns a Ψ-booleanindicating whether this object represents a zero value.- Specified by:
psyIsZeroin interfacePsyArithmetic<PsyNumeric>- Returns:
PsyBoolean.TRUEif this object represents a zero value, andPsyBoolean.FALSEotherwise.
-
psySignum
public PsyBigInteger psySignum()
Description copied from interface:PsyRealNumericReturns the signum of this object.- Specified by:
psySignumin interfacePsyRealNumeric- Returns:
- the Ψ-
realnumericsignum of this object.
-
psyCmp
public PsyInteger psyCmp(PsyRealNumeric oNumeric)
Description copied from interface:PsyScalarCompares this object against given object and returns a Ψ-integerindicating the result of the comparison. Returns negative value if this object is less than given one, zero if this object is equal to given one, and positive value if this object is greater than given one.- Specified by:
psyCmpin interfacePsyScalar<PsyRealNumeric>- Parameters:
oNumeric- an object with which this object is compared.- Returns:
- a result of the comparison.
-
toSyntaxString
public String toSyntaxString()
- Specified by:
toSyntaxStringin interfacePsyObject
-
-