MultiplyBy

See javadoc - uk.gov.gchq.koryphe.impl.function.MultiplyBy

Available since Koryphe version 1.0.0

Multiply the input integer by the provide number.

Examples

Multiply by 2

Java
JSON
Full JSON
Python
final MultiplyBy function = new MultiplyBy(2);
{
  "class" : "MultiplyBy",
  "by" : 2
}
{
  "class" : "uk.gov.gchq.koryphe.impl.function.MultiplyBy",
  "by" : 2
}
g.MultiplyBy( 
  by=2 
)

Input type:

java.lang.Integer

Example inputs:

Input TypeInputResult TypeResult
java.lang.Integer6java.lang.Integer12
java.lang.Integer5java.lang.Integer10
nullnull
java.lang.Double6.1ClassCastException: java.lang.Double cannot be cast to java.lang.Integer

results matching ""

    No results matching ""