Date: Wednesday March 06, 2019 @ 06:02 Author: argrath Update of /cvsroot/perldocjp/docs/modules/File-Temp-0.22 In directory sf-cvs:/tmp/cvs-serv20394/modules/File-Temp-0.22 Modified Files: Temp.pod Log Message: in progress =================================================================== File: Temp.pod Status: Up-to-date Working revision: 1.2 Tue Mar 5 21:02:19 2019 Repository revision: 1.2 /cvsroot/perldocjp/docs/modules/File-Temp-0.22/Temp.pod,v Existing Tags: No Tags Exist -------------- next part -------------- Index: docs/modules/File-Temp-0.22/Temp.pod diff -u docs/modules/File-Temp-0.22/Temp.pod:1.1 docs/modules/File-Temp-0.22/Temp.pod:1.2 --- docs/modules/File-Temp-0.22/Temp.pod:1.1 Mon Mar 4 04:05:05 2019 +++ docs/modules/File-Temp-0.22/Temp.pod Wed Mar 6 06:02:19 2019 @@ -145,9 +145,8 @@ =end original -The following interfaces are provided for compatibility with -existing APIs. They should not be used in new code. -(TBT) +°Ê²¼¤Î¥¤¥ó¥¿¡¼¥Õ¥§¡¼¥¹¤Ï´û¸¤Î API ¤È¤Î¸ß´¹À¤Î¤¿¤á¤ËÄ󶡤µ¤ì¤Æ¤¤¤Þ¤¹¡£ +¤³¤ì¤é¤Ï¿·¤·¤¤¥³¡¼¥É¤Ç¤Ï»È¤¦¤Ù¤¤Ç¤Ï¤¢¤ê¤Þ¤»¤ó¡£ =begin original @@ -292,11 +291,9 @@ =end original -This is the primary interface for interacting with -C<File::Temp>. Using the OO interface a temporary file can be created -when the object is constructed and the file can be removed when the -object is no longer required. -(TBT) +¤³¤ì¤Ï C<File::Temp> ¤ÈÁê¸ßºîÍѤ¹¤ë¤¿¤á¤Î¼ç¥¤¥ó¥¿¡¼¥Õ¥§¡¼¥¹¤Ç¤¹¡£ +OO ¥¤¥ó¥¿¡¼¥Õ¥§¡¼¥¹¤ò»È¤¦¤³¤È¤Ç¡¢¥ª¥Ö¥¸¥§¥¯¥È¤¬ºîÀ®¤µ¤ì¤¿¤È¤¤Ë°ì»þ¥Õ¥¡¥¤¥ë¤¬ +ºîÀ®¤µ¤ì¡¢¥ª¥Ö¥¸¥§¥¯¥È¤¬ÉÔÍפˤʤ俤Ȥ¤Ë¥Õ¥¡¥¤¥ë¤¬ºï½ü¤µ¤ì¤Þ¤¹¡£ =begin original @@ -309,13 +306,13 @@ =end original -Note that there is no method to obtain the filehandle from the -C<File::Temp> object. The object itself acts as a filehandle. Also, -the object is configured such that it stringifies to the name of the -temporary file, and can be compared to a filename directly. The object -isa C<IO::Handle> and isa C<IO::Seekable> so all those methods are -available. -(TBT) +C<File::Temp> ¥ª¥Ö¥¸¥§¥¯¥È¤«¤é¥Õ¥¡¥¤¥ë¥Ï¥ó¥É¥ë¤òÆÀ¤ë¥á¥½¥Ã¥É¤Ï¤Ê¤¤¤³¤È¤Ë +Ãí°Õ¤·¤Æ¤¯¤À¤µ¤¤¡£ +¥ª¥Ö¥¸¥§¥¯¥È¼«¿È¤¬¥Õ¥¡¥¤¥ë¥Ï¥ó¥É¥ë¤È¤·¤Æ¿¶¤ëÉñ¤¤¤Þ¤¹¡£ +¤Þ¤¿¡¢¥ª¥Ö¥¸¥§¥¯¥È¤Ïʸ»úÎ󲽤µ¤ì¤ë¤È°ì»þ¥Õ¥¡¥¤¥ë̾¤Ë¤Ê¤ë¤è¤¦¤Ë +ÀßÄꤵ¤ì¤Æ¤¤¤ë¤Î¤Ç¡¢¥Õ¥¡¥¤¥ë̾¤ÈľÀÜÈæ³Ó¤Ç¤¤Þ¤¹¡£ +¥ª¥Ö¥¸¥§¥¯¥È¤Ï C<IO::Handle> ¤Ç¤¢¤ê C<IO::Seekable> ¤Ç¤¢¤ë¤Î¤Ç +¤³¤ì¤é¤ÎÁ´¤Æ¤Î¥á¥½¥Ã¥É¤¬ÍøÍѲÄǽ¤Ç¤¹¡£ =over 4 @@ -340,11 +337,10 @@ =end original -by default the object is constructed as if C<tempfile> -was called without options, but with the additional behaviour -that the temporary file is removed by the object destructor -if UNLINK is set to true (the default). -(TBT) +¥Ç¥Õ¥©¥ë¥È¤Ç¤Ï¥ª¥×¥·¥ç¥ó¤Ê¤·¤Ç C<tempfile> ¤¬¸Æ¤Ó½Ð¤µ¤ì¤¿¤«¤Î¤è¤¦¤Ë¤·¤Æ +¥ª¥Ö¥¸¥§¥¯¥È¤¬ºîÀ®¤µ¤ì¤Þ¤¹¤¬¡¢ÄɲäﶤëÉñ¤¤¤È¤·¤Æ¡¢UNLINK ¤¬ +¿¿ (¤³¤ì¤¬¥Ç¥Õ¥©¥ë¥È¤Ç¤¹) ¤Î¾ì¹ç¡¢¥ª¥Ö¥¸¥§¥¯¥È¤Î¥Ç¥¹¥È¥é¥¯¥¿¤Ë¤è¤Ã¤Æ +°ì»þ¥Õ¥¡¥¤¥ë¤Ïºï½ü¤µ¤ì¤Þ¤¹¡£ =begin original @@ -355,11 +351,10 @@ =end original -Supported arguments are the same as for C<tempfile>: UNLINK -(defaulting to true), DIR, EXLOCK and SUFFIX. Additionally, the filename -template is specified using the TEMPLATE option. The OPEN option -is not supported (the file is always opened). -(TBT) +Âбþ¤·¤Æ¤¤¤ë°ú¿ô¤Ï C<tempfile> ¤ÈƱ¤¸¤Ç¤¹: UNLINK +(¥Ç¥Õ¥©¥ë¥È¤Ï¿¿), DIR, EXLOCK, SUFFIX¡£ +¤µ¤é¤Ë¡¢¥Õ¥¡¥¤¥ë̾¥Æ¥ó¥×¥ì¡¼¥È¤Ï TEMPLATE ¥ª¥×¥·¥ç¥ó¤ò»È¤Ã¤Æ»ØÄꤷ¤Þ¤¹¡£ +OPEN ¥ª¥×¥·¥ç¥ó¤ÏÂбþ¤·¤Æ¤¤¤Þ¤»¤ó (¥Õ¥¡¥¤¥ë¤Ï¾ï¤Ë³«¤«¤ì¤Þ¤¹)¡£ $tmp = File::Temp->new( TEMPLATE => 'tempXXXXX', DIR => 'mydir', @@ -391,8 +386,7 @@ =end original -Create a temporary directory using an object oriented interface. -(TBT) +¥ª¥Ö¥¸¥§¥¯¥È»Ø¸þ¥¤¥ó¥¿¡¼¥Õ¥§¡¼¥¹¤ò»È¤Ã¤Æ°ì»þ¥Ç¥£¥ì¥¯¥È¥ê¤òºîÀ®¤·¤Þ¤¹¡£ $dir = File::Temp->newdir(); @@ -402,8 +396,7 @@ =end original -By default the directory is deleted when the object goes out of scope. -(TBT) +¥Ç¥Õ¥©¥ë¥È¤Ç¤Ï¡¢¥ª¥Ö¥¸¥§¥¯¥È¤¬¥¹¥³¡¼¥×³°¤Ë¤Ê¤ë¤È¥Ç¥£¥ì¥¯¥È¥ê¤Ïºï½ü¤µ¤ì¤Þ¤¹¡£ =begin original @@ -412,9 +405,10 @@ =end original -Supports the same options as the C<tempdir> function. Note that directories -created with this method default to CLEANUP => 1. -(TBT) +Supports the same options as the +C<tempdir> ´Ø¿ô¤ÈƱ¤¸¥ª¥×¥·¥ç¥ó¤ËÂбþ¤·¤Æ¤¤¤Þ¤¹¡£ +¤³¤Î¥á¥½¥Ã¥É¤Çºî¤é¤ì¤¿¥Ç¥£¥ì¥¯¥È¥ê¤Ï¥Ç¥Õ¥©¥ë¥È¤Ç CLEANUP => 1 ¤Ë¤Ê¤ë¤³¤È¤Ë +Ãí°Õ¤·¤Æ¤¯¤À¤µ¤¤¡£ $dir = File::Temp->newdir( $template, %options ); @@ -429,9 +423,8 @@ =end original -Return the name of the temporary file associated with this object -(if the object was created using the "new" constructor). -(TBT) +(¤³¤Î¥ª¥Ö¥¸¥§¥¯¥È¤¬ "new" ¥³¥ó¥¹¥È¥é¥¯¥¿¤ò»È¤Ã¤ÆºîÀ®¤µ¤ì¤Æ¤¤¤ì¤Ð) +¤³¤Î¥ª¥Ö¥¸¥§¥¯¥È¤Ë´ØÏ¢ÉÕ¤±¤é¤ì¤¿°ì»þ¥Õ¥¡¥¤¥ë̾¤òÊÖ¤·¤Þ¤¹¡£ $filename = $tmp->filename; @@ -442,9 +435,8 @@ =end original -This method is called automatically when the object is used as -a string. -(TBT) +¤³¤Î¥á¥½¥Ã¥É¤Ï¡¢¤³¤Î¥ª¥Ö¥¸¥§¥¯¥È¤¬Ê¸»úÎó¤È¤·¤Æ»È¤ï¤ì¤ë¤È¼«Æ°Åª¤Ë +¸Æ¤Ó½Ð¤µ¤ì¤Þ¤¹¡£ =cut @@ -457,9 +449,8 @@ =end original -Return the name of the temporary directory associated with this -object (if the object was created using the "newdir" constructor). -(TBT) +(¤³¤Î¥ª¥Ö¥¸¥§¥¯¥È¤¬ "newdir" ¥³¥ó¥¹¥È¥é¥¯¥¿¤ò»È¤Ã¤ÆºîÀ®¤µ¤ì¤Æ¤¤¤ì¤Ð) +¤³¤Î¥ª¥Ö¥¸¥§¥¯¥È¤Ë´ØÏ¢ÉÕ¤±¤é¤ì¤¿°ì»þ¥Ç¥£¥ì¥¯¥È¥ê̾¤òÊÖ¤·¤Þ¤¹¡£ $dirname = $tmpdir->dirname; @@ -469,8 +460,8 @@ =end original -This method is called automatically when the object is used in string context. -(TBT) +¤³¤Î¥á¥½¥Ã¥É¤Ï¡¢¤³¤Î¥ª¥Ö¥¸¥§¥¯¥È¤¬Ê¸»úÎó¥³¥ó¥Æ¥¥¹¥È¤Ç»È¤ï¤ì¤ë¤È¼«Æ°Åª¤Ë +¸Æ¤Ó½Ð¤µ¤ì¤Þ¤¹¡£ =item B<unlink_on_destroy> @@ -481,9 +472,9 @@ =end original -Control whether the file is unlinked when the object goes out of scope. -The file is removed if this value is true and $KEEP_ALL is not. -(TBT) +¥ª¥Ö¥¸¥§¥¯¥È¤¬¥¹¥³¡¼¥×³°¤Ë¤Ê¤Ã¤¿¤È¤¤Ë¥Õ¥¡¥¤¥ë¤òºï½ü(unlink)¤¹¤ë¤«¤É¤¦¤«¤ò +À©¸æ¤·¤Þ¤¹¡£ +¤³¤ÎÃͤ¬¿¿¤Ç¡¢$KEEP_ALL ¤¬¿¿¤Ç¤Ê¤±¤ì¤Ð¡¢¥Õ¥¡¥¤¥ë¤Ïºï½ü¤µ¤ì¤Þ¤¹¡£ $fh->unlink_on_destroy( 1 ); @@ -493,8 +484,7 @@ =end original -Default is for the file to be removed. -(TBT) +¥Ç¥Õ¥©¥ë¥È¤Ç¤Ï¥Õ¥¡¥¤¥ë¤Ïºï½ü¤µ¤ì¤Þ¤¹¡£ =cut @@ -509,11 +499,10 @@ =end original -When the object goes out of scope, the destructor is called. This -destructor will attempt to unlink the file (using C<unlink1>) -if the constructor was called with UNLINK set to 1 (the default state -if UNLINK is not specified). -(TBT) +¥ª¥Ö¥¸¥§¥¯¥È¤¬¥¹¥³¡¼¥×³°¤Ë¤Ê¤Ã¤¿¤È¤¡¢¥Ç¥¹¥È¥é¥¯¥¿¤¬¸Æ¤Ó½Ð¤µ¤ì¤Þ¤¹¡£ +¤³¤Î¥Ç¥¹¥È¥é¥¯¥¿¤Ï¡¢UNLINK ¤ò 1 (UNLINK ¤¬»ØÄꤵ¤ì¤Ê¤«¤Ã¤¿¾ì¹ç¤Î¥Ç¥Õ¥©¥ë¥È¤Ï +¤³¤ì¤Ç¤¹)¤ËÀßÄꤷ¤Æ¥³¥ó¥¹¥È¥é¥¯¥¿¤¬¸Æ¤Ó½Ð¤µ¤ì¤Æ¤¤¤ë¤È¡¢(C<unlink1> ¤ò»È¤Ã¤Æ) +¥Õ¥¡¥¤¥ë¤òºï½ü¤·¤è¤¦¤È¤·¤Þ¤¹¡£ =begin original @@ -521,8 +510,7 @@ =end original -No error is given if the unlink fails. -(TBT) +ºï½ü¤Ë¼ºÇÔ¤·¤Æ¤â¥¨¥é¡¼¤ÏȯÀ¸¤·¤Þ¤»¤ó¡£ =begin original @@ -531,9 +519,8 @@ =end original -If the object has been passed to a child process during a fork, the -file will be deleted when the object goes out of scope in the parent. -(TBT) +¥Õ¥©¡¼¥¯¤Ë¤è¤Ã¤Æ¤³¤Î¥ª¥Ö¥¸¥§¥¯¥È¤¬»Ò¥×¥í¥»¥¹¤ËÅϤµ¤ì¤ë¤È¡¢ +¿Æ¤Ç¤³¤Î¥ª¥Ö¥¸¥§¥¯¥È¤¬¥¹¥³¡¼¥×³°¤Ë¤Ê¤Ã¤¿¤È¤¤Ë¥Õ¥¡¥¤¥ë¤Ïºï½ü¤µ¤ì¤Þ¤¹¡£ =begin original @@ -543,10 +530,10 @@ =end original -For a temporary directory object the directory will be removed -unless the CLEANUP argument was used in the constructor (and set to -false) or C<unlink_on_destroy> was modified after creation. -(TBT) +°ì»þ¥Ç¥£¥ì¥¯¥È¥ê¥ª¥Ö¥¸¥§¥¯¥È¤Ë¤Ä¤¤¤Æ¤Ï¡¢¥³¥ó¥¹¥È¥é¥¯¥¿¤Ç +CLEANUP °ú¿ô¤¬»È¤ï¤ì(¤½¤·¤Æµ¶¤ËÀßÄꤵ¤ì)¤ë¤«¡¢ +ºîÀ®¸å¤Ë C<unlink_on_destroy> ¤¬Êѹ¹¤µ¤ì¤Ê¤¤¸Â¤ê¡¢ +¥Ç¥£¥ì¥¯¥È¥ê¤Ïºï½ü¤µ¤ì¤Þ¤¹¡£ =begin original @@ -555,9 +542,7 @@ =end original -If the global variable $KEEP_ALL is true, the file or directory -will not be removed. -(TBT) +¥°¥í¡¼¥Ð¥ëÊÑ¿ô $KEEP_ALL ¤¬¿¿¤Î¾ì¹ç¡¢¥Õ¥¡¥¤¥ë¤ä¥Ç¥£¥ì¥¯¥È¥ê¤Ïºï½ü¤µ¤ì¤Þ¤»¤ó¡£ =cut @@ -693,9 +678,8 @@ =end original -Use the object-oriented interface if fine-grained control of when -a file is removed is required. -(TBT) +¤¤¤Ä¥Õ¥¡¥¤¥ë¤¬ºï½ü¤µ¤ì¤ë¤«¤Ë¤Ä¤¤¤Æ¤ÎºÙ¤«¤¤À©¸æ¤¬É¬Íפʾì¹ç¤Ï¡¢ +¥ª¥Ö¥¸¥§¥¯¥È»Ø¸þ¥¤¥ó¥¿¡¼¥Õ¥§¡¼¥¹¤ò»È¤Ã¤Æ¤¯¤À¤µ¤¤¡£ =begin original @@ -818,7 +802,7 @@ =end original ¤³¤ì¤Ï¡¢°ì»þ¥Ç¥£¥ì¥¯¥È¥ê¤òºîÀ®¤¹¤ë¤¿¤á¤Î¿ä¾©¤µ¤ì¤ë¥¤¥ó¥¿¡¼¥Õ¥§¡¼¥¹¤Ç¤¹¡£ -directories. By default the directory will not be removed on exit +By default the directory will not be removed on exit (that is, it won't be temporary; this behaviour can not be changed because of issues with backwards compatibility). To enable removal either use the CLEANUP option which will trigger removal on program @@ -1474,10 +1458,10 @@ =end original -This function is disabled if the global variable $KEEP_ALL is true -and an unlink on open file is supported. If the unlink is to be deferred -to the END block, the file is still registered for removal. -(TBT) +¤³¤Î´Ø¿ô¤Ï¡¢¥°¥í¡¼¥Ð¥ëÊÑ¿ô $KEEP_ALL ¤¬¿¿¤Ç¡¢³«¤¤¤Æ¤¤¤ë¥Õ¥¡¥¤¥ë¤Î +unlink ¤ËÂбþ¤·¤Æ¤¤¤ë¾ì¹ç¡¢¤³¤Î´Ø¿ô¤Ï̵¸ú¤Ë¤Ê¤ê¤Þ¤¹¡£ +unlink ¤¬ END ¥Ö¥í¥Ã¥¯¤Þ¤ÇÃٱ䤵¤ì¤ë¾ì¹ç¡¢¤³¤Î¥Õ¥¡¥¤¥ë¤Ï +ºï½ü¤Î¤¿¤á¤ËÅÐÏ¿¤µ¤ì¤¿¤Þ¤Þ¤Ç¤¹¡£ =begin original @@ -1552,8 +1536,7 @@ =end original -Not exported by default. -(TBT) +¥Ç¥Õ¥©¥ë¥È¤Ç¤Ï¥¨¥¯¥¹¥Ý¡¼¥È¤µ¤ì¤Þ¤»¤ó¡£ =cut @@ -1585,8 +1568,8 @@ =end original -Usually called from the object destructor when using the OO interface. -(TBT) +Ä̾ï¤Ï¡¢OO ¥¤¥ó¥¿¡¼¥Õ¥§¡¼¥¹¤ò»È¤¦¤È¤¤Ë¥ª¥Ö¥¸¥§¥¯¥È¤Î¥Ç¥¹¥È¥é¥¯¥¿¤«¤é +¸Æ¤Ó½Ð¤µ¤ì¤Þ¤¹¡£ =begin original @@ -1594,8 +1577,7 @@ =end original -Not exported by default. -(TBT) +¥Ç¥Õ¥©¥ë¥È¤Ç¤Ï¥¨¥¯¥¹¥Ý¡¼¥È¤µ¤ì¤Þ¤»¤ó¡£ =begin original @@ -1603,8 +1585,7 @@ =end original -This function is disabled if the global variable $KEEP_ALL is true. -(TBT) +¤³¤Î´Ø¿ô¤Ï¡¢$KEEP_ALL ¤¬¿¿¤Î¾ì¹ç¤Ï̵¸ú¤Ë¤Ê¤ê¤Þ¤¹¡£ =begin original @@ -1613,9 +1594,8 @@ =end original -Can call croak() if there is a security anomaly during the stat() -comparison. -(TBT) +stat() Èæ³Ó¤Î¤È¤¤Ë¥»¥¥å¥ê¥Æ¥£¤ÎÌäÂ꤬¤¢¤ë¾ì¹ç¤Ï croak() ¤ò +¸Æ¤Ö¤³¤È¤¬¤¢¤ê¤Þ¤¹¡£ =cut @@ -1659,8 +1639,7 @@ =end original -Not exported by default. -(TBT) +¥Ç¥Õ¥©¥ë¥È¤Ç¤Ï¥¨¥¯¥¹¥Ý¡¼¥È¤µ¤ì¤Þ¤»¤ó¡£ =back @@ -1918,8 +1897,7 @@ =end original -Default is for files to be removed as requested by the caller. -(TBT) +¥Ç¥Õ¥©¥ë¥È¤Ï¡¢¸Æ¤Ó½Ð¤·¸µ¤Ë¤è¤Ã¤ÆÍ׵ᤵ¤ì¤¿¾ì¹ç¤Ë¥Õ¥¡¥¤¥ë¤òºï½ü¤·¤Þ¤¹¡£ =begin original @@ -1944,8 +1922,7 @@ =end original -Controls whether debugging messages should be enabled. -(TBT) +¥Ç¥Ð¥Ã¥°¥á¥Ã¥»¡¼¥¸¤ò͸ú¤Ë¤¹¤ë¤«¤É¤¦¤«¤òÀ©¸æ¤·¤Þ¤¹¡£ $File::Temp::DEBUG = 1; @@ -1955,8 +1932,7 @@ =end original -Default is for debugging mode to be disabled. -(TBT) +¥Ç¥Õ¥©¥ë¥È¤Ï¡¢¥Ç¥Ð¥Ã¥°¥â¡¼¥É¤ò̵¸ú¤Ë¤·¤Þ¤¹¡£ =back @@ -2095,10 +2071,10 @@ =end original -The file returned by File::Temp will have been opened in binary mode -if such a mode is available. If that is not correct, use the C<binmode()> -function to change the mode of the filehandle. -(TBT) +File::Temp ¤«¤éÊÖ¤µ¤ì¤¿¥Õ¥¡¥¤¥ë¤Ï¡¢(¥â¡¼¥É¤¬¤¢¤ë¾ì¹ç¤Ï)¥Ð¥¤¥Ê¥ê¥â¡¼¥É¤Ç +³«¤«¤ì¤Þ¤¹¡£ +¤³¤ì¤¬Àµ¤·¤¯¤Ê¤¤¾ì¹ç¡¢¥Õ¥¡¥¤¥ë¥Ï¥ó¥É¥ë¤Î¥â¡¼¥É¤òÊѹ¹¤¹¤ë¤¿¤á¤Ë +C<binmode()> ´Ø¿ô¤ò»È¤Ã¤Æ¤¯¤À¤µ¤¤¡£ =begin original @@ -2107,9 +2083,8 @@ =end original -Note that you can modify the encoding of a file opened by File::Temp -also by using C<binmode()>. -(TBT) +C<binmode()> ¤ò»È¤¦¤³¤È¤Ç¡¢File::Temp ¤Ë¤è¤Ã¤Æ³«¤«¤ì¤¿¥Õ¥¡¥¤¥ë¤Î +¥¨¥ó¥³¡¼¥Ç¥£¥ó¥°¤òÊѹ¹¤Ç¤¤ë¤³¤È¤ËÃí°Õ¤·¤Æ¤¯¤À¤µ¤¤¡£ =head1 HISTORY @@ -2155,9 +2130,8 @@ =end original -See L<File::Tempdir> for an alternative object-oriented wrapper for -the C<tempdir> function. -(TBT) +¤â¤¦°ì¤Ä¤Î C<tempdir> ´Ø¿ô¤Î¥ª¥Ö¥¸¥§¥¯¥È»Ø¸þ¤Î¥é¥Ã¥Ñ¡¼¤Ë¤Ä¤¤¤Æ¤Ï +L<File::Tempdir> ¤ò»²¾È¤·¤Æ¤¯¤À¤µ¤¤¡£ =head1 AUTHOR