³¯Â¥ :: Çڵ鷯½±Áö¸¸ ¿ÏÀüÇÑ ³¯Â¥ °´Ã¼ (1.1) | |
Áö±Ý ´Ù¿î·Îµå |
³¯Â¥ :: Çڵ鷯 ¼øÀ§ ¹× ¿ä¾à
±¤°í
- ƯÇã:
- Perl Artistic License
- °¡°Ý:
- FREE
- °Ô½ÃÀÚ À̸§:
- Benoit Beausejour
- °Ô½ÃÀÚ À¥»çÀÌÆ®:
- http://search.cpan.org/~bbeausej/DBIx-Sequence-1.5/Sequence.pm
³¯Â¥ :: Çڵ鷯 ű×
³¯Â¥ :: Çڵ鷯 ¼³¸í
½±Áö¸¸ ¿ÏÀüÇÑ ³¯Â¥ °´Ã¼ (1.1) ³¯Â¥ :: Çڵ鷯´Â ½±Áö¸¸ ¿ÏÀüÇÑ ³¯Â¥ °´Ã¼ (1.1)ÀÔ´Ï´Ù. ½Ä ³ëÇÁ »ç¿ë Date :: Handler; MY $ DATE = NEW DATE :: Handler ({date => time, time_zone => 'À¯·´ / Æĸ®', locale => 'french'}); MY $ DATE = NEW DATE :: Handler ({DATE => , TIME_ZONE => est ',}); My $ date = new date :: handler ({date => {year => month => 4, day => 12, ½Ã°£ => 3, min => 1, sec => 55,}, time_zone => 'america / los_angeles', locale => 'en_us',}); $ DATE Àμâ; "$ date"¸¦ ÀμâÇϽʽÿÀ; $ DATE-> allinfo () Àμâ $ date-> new () »ý¼ºÀÚ $ date-> year () 2001 $ date-> month () 1..12 $ date-> day () 1.31 $ date-> ½Ã°£ () 0.23 $ ³¯Â¥ -> min () 0..59 $ date-> sec () 0..59 $ date-> epoch (GMT) $ date-> timezone () ¾Æ¸Þ¸®Ä« / ¸óÆ®¸®¿Ã, EST, PST $ DATE-> ·ÎÄÌ () ÇÁ¶û½º¾î, en_US, FR_FR, ½ºÆäÀÎ¾î µî $ DATE-> SETLOCALE (Locale)Àº ·ÎÄÉÀÏÀ» Àμö·Î ¼³Á¤ÇÏ°í ·ÎÄÌ ¶Ç´Â ÇØÁ¦¸¦ ¹ÝȯÇÕ´Ï´Ù. $ date-> localerealname () ÇöÀç ·ÎÄÉÀÏÀÇ ½Ç¼ö $ date-> timezonename () estr, pst on $ date-> localtime () objectÀÇ ophoch $ date-> timeformat ($ format_string) strftime $ ³¯Â¥ -> GMTTime () °´Ã¼ÀÇ EPOCH $ DATE-> UTCTIME () GMTTIME () $ DATE-> GMTOFFSET () ¿ÀÇÁ¼ÂÀÇ ¿ÀÇÁ¼Â $ DATE-> MENTHNAME () 4 ¿ù $ dewname () 4 ¿ù () 4 ¿ù $ dewname () 1..7 (¿ù¿äÀÏ 1 ¿ù) $ DATE-> Weekdayname () ¼ö¿äÀÏ $ Date-> FirstWeekdayofmonth () 1..7 $ date-> weekofmonth () 1..4 $ date-> ÀÏ¿ø () 31,30,29 , 28 °³¿ù ¹× ³â¿¡ µû¶ó ´Ù¸¨´Ï´Ù. $ date-> isleapyear () 1 true, false $ date-> daylightsavings () 1À̸é 0À̸é false $ date-> dayofyear () $ date-> daysinyear ()¸¦ ¹ÝȯÇÕ´Ï´Ù. ¿ÃÇØÀÇ ÀϼöÀÔ´Ï´Ù. $ DATE-> DaysLeftIneear ()´Â $ DATE-> ARARY2EPOCH ([]) ¸¦ EPOCH TIME $ DATE-> ASSCALAR ()À¸·Î Àü¼ÛÇÏ´Â ÀÏ ¼ö¸¦ ¹ÝȯÇÕ´Ï´Ù. TimeFormat ( "% a, % b % e % y % r (% z)") $ date-> asnumber () $ date-> asarray () $ DATE-> ASHASH () ¸®ÅÏ {¿¬µµ => y, ¿ù => m, day => d, hour => h, min => mm, sec => ss} $ date-> allinfo () ¸ðµç °´Ã¼ÀÇ °ü·Ã Á¤º¸°¡ Æ÷ÇÔ µÈ ¹®ÀÚ¿À» ¹ÝȯÇÕ´Ï´Ù. ³» $ delta = »õ ³¯Â¥ :: Çڵ鷯 :: µ¨Å¸ (); ³» $ delta = »õ ³¯Â¥ :: Çڵ鷯 :: µ¨Å¸ ({yeary => 3, month => 1 ÀÏ => 10, ½Ã°£ => 2 ºÐ => 5, ÃÊ => 5,}); $ delta-> New (Perldoc Date :: Handler :: Delta) $ delta-> months () µ¨Å¸ $ delta-> seconds () µ¨Å¸ $ delta-> asscalar ()ÀÇ ÃÊ (ÃÊ) ¼ö % D °³¿ù ¹× % d ÃÊ "$ delta-> asnumber ()"% d-% d-% d "$ delta-> asarray () $ delta-> Abash () {Meanner => m, seconds => ss} $ date + $ delta = date :: handler $ date - $ deleta = date :: handler $ date - $ date2 = date :: handler :: delta $ date + n = (+ n ÃÊ) $ date - n = (-n ÃÊ) $ delta + $ delta = date :: handler :: delta $ delta - $ delta = date :: handler :: delta $ delta * n = date :: handler :: delta $ delta / n = ³¯Â¥ :: Çڵ鷯 :: µ¨Å¸ $ delta + n = (+ n ÃÊ) $ delta - n = (-n seconds) my $ range = ³¯Â¥ :: Çڵ鷯 :: ¹üÀ§ -> new ({date => $ ³¯Â¥, µ¨Å¸ => $ delta,}); MY $ RANGE = DATE :: Handler :: Range-> New ({date => , µ¨Å¸ => ,}) ...¿¡ $ RANGE-> NEW (Perldoc ³¯Â¥ :: Çڵ鷯 :: ¹üÀ§ÀÇ Ãß°¡ Á¤º¸) $ range-> direction () ¹üÀ§ÀÇ ¹æÇâ ( 'forwards'|| 'µÚ·Î') $ range-> startdate () ½ÃÀÛ ³¯Â¥ ::ÀÌ ¹üÀ§ ¹× ¹æÇâÀÇ Çڵ鷯 °³Ã¼ $ RANGE-> ENDDATE () Á¾·á ³¯Â¥ :: ¹æÇâ ¹× ¹æÇâÀÇ Çڵ鷯 °³Ã¼ $ RANGE-> °ãħ ($ RANGE2)Àº ¹üÀ§°¡ ¹üÀ§¸¦ °ãÄ¡¸é TRUE¸¦ ¹ÝȯÇÕ´Ï´Ù. Undefrise.date::Hantler´Â ½Ã°£´ë¿¡¼ ½Ã°£´ë¿Í Çü½Ä ÀÚü·Î º¯È¯ÇÏ´Â ¸ðµç ¸Þ¼Òµå¸¦ º¸À¯ÇÏ°íÀÖ´Â ³¯Â¥ÀÇ ÄÁÅ×À̳ÊÀÔ´Ï´Ù. ÀÌ ¸ðµâ ¾ÆÀ̵ð¾î´Â Module Ŭ·¡½º¿¡¼ DLUX (Szab, Balzs)°¡ ÀÛ¼ºÇÑ ¿ø·¡ ¹öÀü¿¡¼ ³ª¿É´Ï´Ù. DATE.DATE :: Handler´Â POSIX ¸ðµâÀ» »ç¿ëÇÏ¿© ¼ø¼öÇÑ Perl¿¡¼ ±¸ÇöµÇ¸ç ȯ°æ º¯¼ö TZ°¡ IT ½Ã°£´ë °ü¸®¸¦ À§ÇØ Ä¸½¶ÈÇÕ´Ï´Ù. ±¸Çö¿¡¼ ¿ÜºÎ ÀûÀ¸·Î Ç÷¹ÀÌ ÇÒ ÇÊ¿ä°¡ ¾ø½À´Ï´Ù. ³¯Â¥ :: Çڵ鷯´Â ¶ÇÇÑ POSIX¸¦ »ç¿ëÇÏ¿© ÇöÁöȸ¦ Áö¿øÇÕ´Ï´Ù .It´Â ¿î¿µÀÚ °úºÎÇÏ ¹× µ¨Å¸ ³¯Â¥ °³Ã¼¸¦ »ç¿ëÇÏ¿© ½Ã°£ Â÷À̸¦ °è»êÇÕ´Ï´Ù. ¿ä±¸ »çÇ× : ¡¤ Perl.
³¯Â¥ :: Çڵ鷯 °ü·Ã ¼ÒÇÁÆ®¿þ¾î