{"id":463,"date":"2005-08-04T01:00:00","date_gmt":"2005-08-03T16:00:00","guid":{"rendered":"https:\/\/ecoop.net\/memo\/2005-08-04-1.html"},"modified":"2005-08-04T01:00:00","modified_gmt":"2005-08-03T16:00:00","slug":"2005-08-04-1","status":"publish","type":"post","link":"https:\/\/www.ecoop.net\/memo\/archives\/2005-08-04-1.html","title":{"rendered":"\u30df\u30ea\u79d2\u5358\u4f4d\u306e\u6642\u9593\u306e\u53d6\u5f97\u3092\u3059\u308b"},"content":{"rendered":"<p>\n\u53e4\u3044\u30e1\u30e2\u306b\u3042\u3063\u305f\u3082\u306e\u3092\u6574\u7406\u306e\u305f\u3081\u5199\u3057\u305f\u3002\n<\/p>\n<blockquote><p>\/\/ \u6642\u9593\u3092\u30df\u30ea\u79d2\u3067\u8fd4\u3059<br \/>\n\/\/ (clockid_t\u306b\u3088\u308a\u52d5\u4f5c\u304c\u5909\u308f\u308b\/CLOCK_REALTIME\u306e\u5834\u5408\u30b7\u30b9\u30c6\u30e0\u306e\u5b9f\u6642\u9593\u6642\u8a08)<br \/>\n\/\/ time.h<br \/>\nint clock_gettime( <br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;clockid_t clock_id, <br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;struct timespec *tp <br \/>\n\t); <br \/>\n\tclockid_t\u306fCLOCK_REALTIME,CLOCK_VIRTUAL\u306a\u3069\u5b9a\u6570\u3067\u6307\u5b9a\u3059\u308b\u3002<br \/>\n\tstruct timespec{<br \/>\n\t        time_t  tv_sec;         \/* seconds *\/<br \/>\n\t\t        long    tv_nsec;        \/* nanoseconds *\/<br \/>\n\t\t\t};<br \/>\n\t\t\ttv_nsec \u306e\u5024\u306f 0 \u301c 999,999,999 \u306e\u7bc4\u56f2\u306b\u306a\u3051\u308c\u3070\u306a\u3089\u306a\u3044\u3002 <br \/>\n\t\t\t\u53c2\u7167: <a href=\"http:\/\/docs.hp.com\/ja\/B2355-60104-05\/rn04re25.html\">http:\/\/docs.hp.com\/ja\/B2355-60104-05\/rn04re25.html<\/a><\/p>\n<p>\t\t\t\u3053\u306e\u95a2\u6570\u306fCygwin\u3067\u306f\u5b9f\u88c5\u3055\u308c\u3066\u304a\u3089\u305a\u3001Windows\u3067\u306f\u6b21\u306e\u95a2\u6570\u3092\u4f7f\u3046\u3002<br \/>\n\t\t\t\/\/ \u8d77\u52d5\u3057\u3066\u304b\u3089\u306e\u6642\u9593\u3092\u30df\u30ea\u79d2\u3067\u8fd4\u3059<br \/>\n\t\t\t\/\/ windows.h<br \/>\n\t\t\tDWORD GetTickCount(void);\n<\/p><\/blockquote>\n<p>&#8211; \u30df\u30ea\u79d2\u4ee5\u4e0b\u306e\u30b9\u30ea\u30fc\u30d7\n<\/p>\n<blockquote><p>\/\/ req \u3067\u6307\u5b9a\u3057\u305f\u6642\u9593\u3001\u30ca\u30ce\u79d2(1000\u30ca\u30ce\u79d2 = 1\u30df\u30ea\u79d2)\u5358\u4f4d\u3067\u51e6\u7406\u3092\u30b9\u30ea\u30fc\u30d7\u3055\u305b\u308b.<br \/>\n\/\/ rem \u306fsignal\u306b\u3088\u3063\u3066\u505c\u6b62\u3057\u305f\u5834\u5408\u306b\u6b8b\u308a\u306e\u6642\u9593\u3092\u683c\u7d0d\u3059\u308b\u305f\u3081\u306e\u3082\u306e\u3067NULL\u3067\u3082<br \/>\n\/\/ \u3088\u3044\u3002signal\u3067\u505c\u6b62\u3057\u305f\u5834\u5408-1\u3092\u8fd4\u3059\u3002<br \/>\n\/\/ time.h<br \/>\nint nanosleep(const struct timespec *req, struct timespec *rem); \n<\/p><\/blockquote>\n<p>\u53c2\u7167: &lt;<a href=\"http:\/\/www.linux.or.jp\/JM\/html\/LDP_man-pages\/man2\/nanosleep.2.html\">http:\/\/www.linux.or.jp\/JM\/html\/LDP_man-pages\/man2\/nanosleep.2.html<\/a>><br \/>\n\u3053\u306e\u95a2\u6570\u306fCygwin\u3067\u306f\u5b9f\u88c5\u3055\u308c\u3066\u3044\u306a\u3044\u304c\u3001Windows\u3067\u306fSleep\u304c\u3042\u308b\u304b\u3089\u4e0d\u8981\u3067\u3059\u306d\u3002\n<\/p>\n<blockquote><p>\/\/ windows.h<br \/>\nvoid Sleep(DWORD dwMilliseconds);\n<\/p><\/blockquote>\n<p>dwMilliseconds=0\u306e\u3068\u304d\u3001\u512a\u5148\u9806\u4f4d\u304c\u7b49\u3057\u304f\u5b9f\u884c\u6e96\u5099\u306e\u3067\u304d\u305f\u4ed6\u306e\u30b9\u30ec\u30c3\u30c9\u306b\u51e6\u7406\u3092\u8b72<br \/>\n\u308b\u3002\u8a72\u5f53\u3059\u308b\u30b9\u30ec\u30c3\u30c9\u304c\u306a\u3044\u5834\u5408\u306f\u5373\u5236\u5fa1\u3092\u8fd4\u3059\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u53e4\u3044\u30e1\u30e2\u306b\u3042\u3063\u305f\u3082\u306e\u3092\u6574\u7406\u306e\u305f\u3081\u5199\u3057\u305f\u3002 \/\/ \u6642\u9593\u3092\u30df\u30ea\u79d2\u3067\u8fd4\u3059 \/\/ (clockid_t\u306b\u3088\u308a\u52d5\u4f5c\u304c\u5909\u308f\u308b\/CLOCK_REALTIME\u306e\u5834\u5408\u30b7\u30b9\u30c6\u30e0\u306e\u5b9f\u6642\u9593\u6642\u8a08) \/\/ time.h int clock_gett &hellip; <a href=\"https:\/\/www.ecoop.net\/memo\/archives\/2005-08-04-1.html\" class=\"more-link\">\u7d9a\u304d\u3092\u8aad\u3080 <span class=\"screen-reader-text\">\u30df\u30ea\u79d2\u5358\u4f4d\u306e\u6642\u9593\u306e\u53d6\u5f97\u3092\u3059\u308b<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[73],"class_list":["post-463","post","type-post","status-publish","format-standard","hentry","tag-c2fc2b2b"],"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/posts\/463","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/comments?post=463"}],"version-history":[{"count":0,"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/posts\/463\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/media?parent=463"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/categories?post=463"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/tags?post=463"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}