本文整理汇总了Java中com.espertech.esper.util.SimpleNumberCoercerFactory.getCoercerBigInteger方法的典型用法代码示例。如果您正苦于以下问题:Java SimpleNumberCoercerFactory.getCoercerBigInteger方法的具体用法?Java SimpleNumberCoercerFactory.getCoercerBigInteger怎么用?Java SimpleNumberCoercerFactory.getCoercerBigInteger使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.espertech.esper.util.SimpleNumberCoercerFactory
的用法示例。
在下文中一共展示了SimpleNumberCoercerFactory.getCoercerBigInteger方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: makeBigIntegerComputer
import com.espertech.esper.util.SimpleNumberCoercerFactory; //导入方法依赖的package包/类
private Computer makeBigIntegerComputer(Class typeOne, Class typeTwo) {
if ((typeOne == BigDecimal.class) && (typeTwo == BigDecimal.class)) {
return computers.get(new MultiKeyUntyped(new Object[]{BigDecimal.class, this}));
}
if ((typeOne == BigInteger.class) && (typeTwo == BigInteger.class)) {
Computer computer = computers.get(new MultiKeyUntyped(new Object[]{BigInteger.class, this}));
if (computer != null) {
return computer;
}
}
SimpleNumberBigIntegerCoercer convertorOne = SimpleNumberCoercerFactory.getCoercerBigInteger(typeOne);
SimpleNumberBigIntegerCoercer convertorTwo = SimpleNumberCoercerFactory.getCoercerBigInteger(typeTwo);
if (this == ADD) {
return new AddBigIntConvComputer(convertorOne, convertorTwo);
}
if (this == SUBTRACT) {
return new SubtractBigIntConvComputer(convertorOne, convertorTwo);
}
if (this == MULTIPLY) {
return new MultiplyBigIntConvComputer(convertorOne, convertorTwo);
}
if (this == DIVIDE) {
return new DivideBigIntConvComputer(convertorOne, convertorTwo);
}
return new ModuloLong();
}
示例2: makeBigIntegerComputer
import com.espertech.esper.util.SimpleNumberCoercerFactory; //导入方法依赖的package包/类
private Computer makeBigIntegerComputer(Class typeOne, Class typeTwo)
{
if ((typeOne == BigDecimal.class) && (typeTwo == BigDecimal.class))
{
return computers.get(new MultiKeyUntyped(new Object[] {BigDecimal.class, this}));
}
SimpleNumberBigIntegerCoercer convertorOne = SimpleNumberCoercerFactory.getCoercerBigInteger(typeOne);
SimpleNumberBigIntegerCoercer convertorTwo = SimpleNumberCoercerFactory.getCoercerBigInteger(typeTwo);
if (this == ADD)
{
return new AddBigIntConvComputer(convertorOne, convertorTwo);
}
if (this == SUBTRACT)
{
return new SubtractBigIntConvComputer(convertorOne, convertorTwo);
}
if (this == MULTIPLY)
{
return new MultiplyBigIntConvComputer(convertorOne, convertorTwo);
}
if (this == DIVIDE)
{
return new DivideBigIntConvComputer(convertorOne, convertorTwo);
}
return new ModuloLong();
}
示例3: ExprBetweenCompBigInteger
import com.espertech.esper.util.SimpleNumberCoercerFactory; //导入方法依赖的package包/类
public ExprBetweenCompBigInteger(boolean lowIncluded, boolean highIncluded, Class valueType, Class lowerType, Class upperType) {
isLowIncluded = lowIncluded;
isHighIncluded = highIncluded;
numberCoercerLower = SimpleNumberCoercerFactory.getCoercerBigInteger(lowerType);
numberCoercerUpper = SimpleNumberCoercerFactory.getCoercerBigInteger(upperType);
numberCoercerValue = SimpleNumberCoercerFactory.getCoercerBigInteger(valueType);
}
示例4: ExprBetweenCompBigInteger
import com.espertech.esper.util.SimpleNumberCoercerFactory; //导入方法依赖的package包/类
public ExprBetweenCompBigInteger(boolean lowIncluded, boolean highIncluded, Class valueType, Class lowerType, Class upperType)
{
isLowIncluded = lowIncluded;
isHighIncluded = highIncluded;
numberCoercerLower = SimpleNumberCoercerFactory.getCoercerBigInteger(lowerType);
numberCoercerUpper = SimpleNumberCoercerFactory.getCoercerBigInteger(upperType);
numberCoercerValue = SimpleNumberCoercerFactory.getCoercerBigInteger(valueType);
}