Query: number::compare
OS: debian
Section: 3pm
Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar
Number::Compare(3pm) User Contributed Perl Documentation Number::Compare(3pm)NAMENumber::Compare - numeric comparisonsSYNOPSISNumber::Compare->new(">1Ki")->test(1025); # is 1025 > 1024 my $c = Number::Compare->new(">1M"); $c->(1_200_000); # slightly terser invocationDESCRIPTIONNumber::Compare compiles a simple comparison to an anonymous subroutine, which you can call with a value to be tested again. Now this would be very pointless, if Number::Compare didn't understand magnitudes. The target value may use magnitudes of kilobytes ("k", "ki"), megabytes ("m", "mi"), or gigabytes ("g", "gi"). Those suffixed with an "i" use the appropriate 2**n version in accordance with the IEC standard: http://physics.nist.gov/cuu/Units/binary.htmlMETHODS->new( $test ) Returns a new object that compares the specified test. ->test( $value ) A longhanded version of $compare->( $value ). Predates blessed subroutine reference implementation. ->parse_to_perl( $test ) Returns a perl code fragment equivalent to the test.AUTHORRichard Clamp <richardc@unixbeard.net>COPYRIGHTCopyright (C) 2002,2011 Richard Clamp. All Rights Reserved. This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself.SEE ALSOhttp://physics.nist.gov/cuu/Units/binary.html perl v5.12.4 2011-09-21 Number::Compare(3pm)
Related Man Pages |
---|
number::compare(3) - mojave |
number::compare(3) - centos |
ppi::token::number(3pm) - debian |
ppi::token::number::version(3pm) - debian |
struct::compare(3pm) - debian |
Similar Topics in the Unix Linux Community |
---|
Provide a count of files |
Compare and extract |
Compare arrays (perl) |
Compare 2 Files |
Compare one file and get the count of multiple file |