perltoc.pod

来自「视频监控网络部分的协议ddns,的模块的实现代码,请大家大胆指正.」· POD 代码 · 共 2,713 行 · 第 1/5 页

POD
2,713
字号
=item DESCRIPTION=item Data: Numbers=over 4=item Why am I getting long decimals (eg, 19.9499999999999) instead of thenumbers I should be getting (eg, 19.95)?=item Why is int() broken?=item Why isn't my octal data interpreted correctly?=item Does Perl have a round() function?  What about ceil() and floor()? Trig functions?=item How do I convert between numeric representations/bases/radixes?How do I convert hexadecimal into decimal, How do I convert from decimal tohexadecimal, How do I convert from octal to decimal, How do I convert fromdecimal to octal, How do I convert from binary to decimal, How do I convertfrom decimal to binary=item Why doesn't & work the way I want it to?=item How do I multiply matrices?=item How do I perform an operation on a series of integers?=item How can I output Roman numerals?=item Why aren't my random numbers random?=item How do I get a random number between X and Y?=back=item Data: Dates=over 4=item How do I find the day or week of the year?=item How do I find the current century or millennium?=item How can I compare two dates and find the difference?=item How can I take a string and turn it into epoch seconds?=item How can I find the Julian Day?=item How do I find yesterday's date?=item Does Perl have a Year 2000 problem? Is Perl Y2K compliant?=back=item Data: Strings=over 4=item How do I validate input?=item How do I unescape a string?=item How do I remove consecutive pairs of characters?=item How do I expand function calls in a string?=item How do I find matching/nesting anything?=item How do I reverse a string?=item How do I expand tabs in a string?=item How do I reformat a paragraph?=item How can I access or change N characters of a string?=item How do I change the Nth occurrence of something?=item How can I count the number of occurrences of a substring within astring?=item How do I capitalize all the words on one line?=item How can I split a [character] delimited string except when inside[character]?=item How do I strip blank space from the beginning/end of a string?=item How do I pad a string with blanks or pad a number with zeroes?=item How do I extract selected columns from a string?=item How do I find the soundex value of a string?=item How can I expand variables in text strings?=item What's wrong with always quoting "$vars"?=item Why don't my E<lt>E<lt>HERE documents work?There must be no space after the E<lt>E<lt> part, There (probably) shouldbe a semicolon at the end, You can't (easily) have any space in front ofthe tag=back=item Data: Arrays=over 4=item What is the difference between a list and an array?=item What is the difference between $array[1] and @array[1]?=item How can I remove duplicate elements from a list or array?=item How can I tell whether a certain element is contained in a list orarray?=item How do I compute the difference of two arrays?  How do I compute theintersection of two arrays?=item How do I test whether two arrays or hashes are equal?=item How do I find the first array element for which a condition is true?=item How do I handle linked lists?=item How do I handle circular lists?=item How do I shuffle an array randomly?=item How do I process/modify each element of an array?=item How do I select a random element from an array?=item How do I permute N elements of a list?X<List::Permuter> X<permute> X<Algorithm::Loops> X<Knuth>X<The Art of Computer Programming> X<Fischer-Krause>=item How do I sort an array by (anything)?=item How do I manipulate arrays of bits?=item Why does defined() return true on empty arrays and hashes?=back=item Data: Hashes (Associative Arrays)=over 4=item How do I process an entire hash?=item What happens if I add or remove keys from a hash while iterating overit?=item How do I look up a hash element by value?=item How can I know how many entries are in a hash?=item How do I sort a hash (optionally by value instead of key)?=item How can I always keep my hash sorted?X<hash tie sort DB_File Tie::IxHash>=item What's the difference between "delete" and "undef" with hashes?=item Why don't my tied hashes make the defined/exists distinction?=item How do I reset an each() operation part-way through?=item How can I get the unique keys from two hashes?=item How can I store a multidimensional array in a DBM file?=item How can I make my hash remember the order I put elements into it?=item Why does passing a subroutine an undefined element in a hash createit?=item How can I make the Perl equivalent of a C structure/C++ class/hash orarray of hashes or arrays?=item How can I use a reference as a hash key?=back=item Data: Misc=over 4=item How do I handle binary data correctly?=item How do I determine whether a scalar is a number/whole/integer/float?=item How do I keep persistent data across program calls?=item How do I print out or copy a recursive data structure?=item How do I define methods for every class/object?=item How do I verify a credit card checksum?=item How do I pack arrays of doubles or floats for XS code?=back=item REVISION=item AUTHOR AND COPYRIGHT=back=head2 perlfaq5 - Files and Formats=over 4=item DESCRIPTION=over 4=item How do I flush/unbuffer an output filehandle?  Why must I do this?X<flush> X<buffer> X<unbuffer> X<autoflush>=item How do I count the number of lines in a file?X<file, counting lines> X<lines> X<line>=item How can I use Perl's C<-i> option from within a program?X<-i> X<in-place>=item How can I copy a file?X<copy> X<file, copy>=item How do I make a temporary file name?X<file, temporary>=item How can I manipulate fixed-record-length files?X<fixed-length> X<file, fixed-length records>=item How can I make a filehandle local to a subroutine?  How do I passfilehandles between subroutines?  How do I make an array of filehandles?X<filehandle, local> X<filehandle, passing> X<filehandle, reference>=item How can I use a filehandle indirectly?X<filehandle, indirect>=item How can I set up a footer format to be used with write()?X<footer>=item How can I write() into a string?X<write, into a string>=item How can I open a filehandle to a string?X<string>, X<open>, X<IO::Scalar>, X<filehandle>=item How can I translate tildes (~) in a filename?X<tilde> X<tilde expansion>=item How come when I open a file read-write it wipes it out?X<clobber> X<read-write> X<clobbering> X<truncate> X<truncating>=item Why do I sometimes get an "Argument list too long" when I useE<lt>*E<gt>?X<argument list too long>=item Is there a leak/bug in glob()?X<glob>=item How can I open a file with a leading ">" or trailing blanks?X<filename, special characters>=item How can I reliably rename a file?X<rename> X<mv> X<move> X<file, rename> X<ren>=item How can I lock a file?X<lock> X<file, lock> X<flock>=item Why can't I just open(FH, "E<gt>file.lock")?X<lock, lockfile race condition>=item I still don't get locking.  I just want to increment the number inthe file.  How can I do this?X<counter> X<file, counter>=item All I want to do is append a small amount of text to the end of afile.  Do I still have to use locking?X<append> X<file, append>=item How do I randomly update a binary file?X<file, binary patch>=item How do I get a file's timestamp in perl?X<timestamp> X<file, timestamp>=item How do I set a file's timestamp in perl?X<timestamp> X<file, timestamp>=item How do I print to more than one file at once?X<print, to multiple files>=item How can I read in an entire file all at once?X<slurp> X<file, slurping>=item How can I read in a file by paragraphs?X<file, reading by paragraphs>=item How can I read a single character from a file?  From the keyboard?X<getc> X<file, reading one character at a time>=item How can I tell whether there's a character waiting on a filehandle?=item How do I do a C<tail -f> in perl?X<tail> X<IO::Handle> X<File::Tail> X<clearerr>=item How do I dup() a filehandle in Perl?X<dup>=item How do I close a file descriptor by number?X<file, closing file descriptors> X<POSIX> X<close>=item Why can't I use "C:\temp\foo" in DOS paths?  Why doesn't`C:\temp\foo.exe` work?X<filename, DOS issues>=item Why doesn't glob("*.*") get all the files?X<glob>=item Why does Perl let me delete read-only files?  Why does C<-i> clobberprotected files?  Isn't this a bug in Perl?=item How do I select a random line from a file?X<file, selecting a random line>=item Why do I get weird spaces when I print an array of lines?=back=item REVISION=item AUTHOR AND COPYRIGHT=back=head2 perlfaq6 - Regular Expressions=over 4=item DESCRIPTION=over 4=item How can I hope to use regular expressions without creating illegibleand unmaintainable code?X<regex, legibility> X<regexp, legibility>X<regular expression, legibility> X</x>Comments Outside the Regex, Comments Inside the Regex, Different Delimiters=item I'm having trouble matching over more than one line.  What's wrong?X<regex, multiline> X<regexp, multiline> X<regular expression, multiline>=item How can I pull out lines between two patterns that are themselves ondifferent lines?X<..>=item I put a regular expression into $/ but it didn't work. What's wrong?X<$/, regexes in> X<$INPUT_RECORD_SEPARATOR, regexes in>X<$RS, regexes in>=item How do I substitute case insensitively on the LHS while preservingcase on the RHS?X<replace, case preserving> X<substitute, case preserving>X<substitution, case preserving> X<s, case preserving>=item How can I make C<\w> match national character sets?X<\w>=item How can I match a locale-smart version of C</[a-zA-Z]/>?X<alpha>=item How can I quote a variable to use in a regex?X<regex, escaping> X<regexp, escaping> X<regular expression, escaping>=item What is C</o> really for?X</o, regular expressions> X<compile, regular expressions>=item How do I use a regular expression to strip C style comments from afile?=item Can I use Perl regular expressions to match balanced text?X<regex, matching balanced test> X<regexp, matching balanced test>X<regular expression, matching balanced test>=item What does it mean that regexes are greedy?  How can I get around it?X<greedy> X<greediness>=item How do I process each word on each line?X<word>=item How can I print out a word-frequency or line-frequency summary?=item How can I do approximate matching?X<match, approximate> X<matching, approximate>=item How do I efficiently match many regular expressions at once?X<regex, efficiency> X<regexp, efficiency>X<regular expression, efficiency>=item Why don't word-boundary searches with C<\b> work for me?X<\b>=item Why does using $&, $`, or $' slow my program down?X<$MATCH> X<$&> X<$POSTMATCH> X<$'> X<$PREMATCH> X<$`>=item What good is C<\G> in a regular expression?X<\G>=item Are Perl regexes DFAs or NFAs?  Are they POSIX compliant?X<DFA> X<NFA> X<POSIX>=item What's wrong with using grep in a void context?X<grep>=item How can I match strings with multibyte characters?X<regex, and multibyte characters> X<regexp, and multibyte characters>X<regular expression, and multibyte characters> X<martian> X<encoding,Martian>=item How do I match a regular expression that's in a variable?X<regex, in variable> X<eval> X<regex> X<quotemeta> X<\Q, regex>X<\E, regex>, X<qr//>=back=item REVISION=item AUTHOR AND COPYRIGHT=back=head2 perlfaq7 - General Perl Language Issues=over 4=item DESCRIPTION=over 4=item Can I get a BNF/yacc/RE for the Perl language?=item What are all these $@%&* punctuation signs, and how do I know when touse them?=item Do I always/never have to quote my strings or use semicolons andcommas?=item How do I skip some return values?=item How do I temporarily block warnings?=item What's an extension?=item Why do Perl operators have different precedence than C operators?=item How do I declare/create a structure?=item How do I create a module?=item How do I adopt or take over a module already on CPAN?=item How do I create a class?=item How can I tell if a variable is tainted?=item What's a closure?=item What is variable suicide and how can I prevent it?=item How can I pass/return a {Function, FileHandle, Array, Hash, Method,Regex}?Passing Variables and Functions, Passing Filehandles, Passing Regexes,Passing Methods=item How do I create a static variable?=item What's the difference between dynamic and lexical (static) scoping? Between local() and my()?=item How can I access a dynamic variable while a similarly named lexicalis in scope?=item What's the difference between deep and shallow binding?=item Why doesn't "my($foo) = E<lt>FILEE<gt>;" work right?=item How do I redefine a builtin function, operator, or method?=item What's the difference between calling a function as &foo and foo()?=item How do I create a switch or case statement?=item How can I catch accesses to undefined variables, functions, ormethods?=item Why can't a method included in this same file be found?=item How can I find out my current package?=item How can I comment out a large block of perl code?=item How do I clear a package?=item How can I use a variable as a variable name?=item What does "bad interpreter" mean?=back=item REVISION=item AUTHOR AND COPYRIGHT=back=head2 perlfaq8 - System Interaction=over 4=item DESCRIPTION=over 4=item How do I find out which operating system I'm running under?=item How come exec() doesn't return?=item How do I do fancy stuff with the keyboard/screen/mouse?

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?