24 package org.lightjason.agentspeak.action.builtin.math.statistic;
34 import javax.annotation.Nonnull;
35 import java.util.Collections;
36 import java.util.List;
37 import java.util.stream.Collectors;
38 import java.util.stream.IntStream;
39 import java.util.stream.Stream;
70 @Nonnull
final List<ITerm> p_argument, @Nonnull
final List<ITerm> p_return )
73 p_argument.size() == 0
76 .map(
ITerm::<Number>raw )
77 .map( Number::intValue )
81 ? Collections.synchronizedList(
82 IntStream.range( 0, i ).mapToDouble( j -> Math.random() ).boxed().collect( Collectors.toList() )
84 : IntStream.range( 0, i ).mapToDouble( j -> Math.random() ).boxed().collect( Collectors.toList() )
87 .forEach( p_return::add );
base class of build-in actions for setting name by package/classname (without prefix character) ...
create a (set) of simple random values.
static< N > IFuzzyValue< N > from( @Nonnull final N p_value)
factory
common structure for execution definition
execution context with local data
static Stream< ITerm > flatten( @Nonnull final Collection<? extends ITerm > p_terms)
flat term-in-term collection into a straight term list
result for an immutable fuzzy value
static< N > CRawTerm< N > from(final N p_value)
factory for a raw term
static final long serialVersionUID
serial id
term structure for simple datatypes
final IFuzzyValue< Boolean > execute(final boolean p_parallel, @Nonnull final IContext p_context, @Nonnull final List< ITerm > p_argument, @Nonnull final List< ITerm > p_return)
defines a plan-body operation