lib/alf/operator/unary.rb in alf-0.10.1 vs lib/alf/operator/unary.rb in alf-0.11.0

- old
+ new

@@ -3,36 +3,14 @@ # # Specialization of Operator for operators that work on a unary input # module Unary include Operator - - # - # Sets the operator input - # - def pipe(input, env = environment) - self.environment = env - self.datasets = [ input ] - self - end - protected - - # - # Simply returns the first dataset - # - def input - Iterator.coerce(datasets.first, environment) + # Simply returns the first operand + def operand + operands.first end - - # - # Yields the block with each input tuple. - # - # This method should be preferred to <code>input.each</code> when possible. - # - def each_input_tuple - input.each(&Proc.new) - end - + end # module Unary end # module Operator end # module Alf