Acme-FishFarm

 view release on metacpan or  search on metacpan

docs/Acme-FishFarm-Feeder-1.01.html  view on Meta::CPAN


<p>Setting this to a true value will give output about the feeder&#39;s situation when feeding the fish.</p>

</li>
</ul>

<h2 id="set_feeding_volume-volume">set_feeding_volume ( $volume )</h2>

<p>Sets the fish food feeding volume.</p>

<p><code>$volume</code> must be a positive number. No error checking is done for this yet.</p>

<h2 id="feeding_volume">feeding_volume</h2>

<p>Returns the amount of food to feed the fish each time the <code>feed_fish</code> method is called.</p>

<h2 id="refill-volume">refill ( $volume )</h2>

<p>Refills the fish food tank <b>TO</b> <code>$volume</code>.</p>

<p>If <code>$volume</code> is not specified, the food tank will be filled to max.</p>

lib/Acme/FishFarm/Feeder.pm  view on Meta::CPAN

        $self->{current_food_amount} = 0;
    } else {
        $self->{current_food_amount} = $self->{current_food_amount} - $self->{feeding_volume};
    }
}

=head2 set_feeding_volume ( $volume )

Sets the fish food feeding volume.

C<$volume> must be a positive number. No error checking is done for this yet.

=cut

sub set_feeding_volume {
    ref (my $self = shift) or croak "Please use this the OO way";
    my $volume = shift or croak "Please specify feeding volume";
    $self->{feeding_volume} = $volume;
}

=head2 feeding_volume

lib/Acme/FishFarm/WaterFiltration.pm  view on Meta::CPAN


sub clean_cylinder {
    no warnings "numeric";
    ref( my $self = shift ) or croak "Please use this the OO way";
    
    my $reduce_waste_by;
    if (@_) {
        my $reduce = shift;
        if ( $reduce < 0 ) {
            $reduce_waste_by = abs($reduce);
            # futhre error checking is done in Acme::FishFarm::check_water_filter
        } else {
            $reduce_waste_by = $reduce;
        }
    } else {
        $reduce_waste_by = 0;
    }
    
    if ( $self->{is_on_spatulas} ) {
        
        if ( $reduce_waste_by ) {



( run in 0.367 second using v1.01-cache-2.11-cpan-65fba6d93b7 )