Linux heracles.o2switch.net 4.18.0-553.62.1.lve.el8.x86_64 #1 SMP Mon Jul 21 17:50:35 UTC 2025 x86_64
/
opt
/
alt
/
ruby27
/
share
/
ri
/
system
/
Process
/
//opt/alt/ruby27/share/ri/system/Process/clock_getres-c.ri
U:RDoc::AnyMethod[iI"clock_getres:ETI"Process::clock_getres;TT:privateo:RDoc::Markup::Document:@parts[o:RDoc::Markup::Paragraph; [I"KReturns the time resolution returned by POSIX clock_getres() function.;To:RDoc::Markup::BlankLine o; ; [I"++clock_id+ specifies a kind of clock. ;TI"=See the document of +Process.clock_gettime+ for details.;T@o; ; [ I"<+clock_id+ can be a symbol as +Process.clock_gettime+. ;TI"-However the result may not be accurate. ;TI"XFor example, <code>Process.clock_getres(:GETTIMEOFDAY_BASED_CLOCK_REALTIME)</code> ;TI"Yreturns 1.0e-06 which means 1 microsecond, but actual resolution can be more coarse.;T@o; ; [I"GIf the given +clock_id+ is not supported, Errno::EINVAL is raised.;T@o; ; [ I"2+unit+ specifies a type of the return value. ;TI"G+Process.clock_getres+ accepts +unit+ as +Process.clock_gettime+. ;TI"9The default value, +:float_second+, is also same as ;TI"+Process.clock_gettime+.;T@o; ; [I"=+Process.clock_getres+ also accepts +:hertz+ as +unit+. ;TI"8+:hertz+ means a the reciprocal of +:float_second+.;T@o; ; [I"7+:hertz+ can be used to obtain the exact value of ;TI"9the clock ticks per second for times() function and ;TI")CLOCKS_PER_SEC for clock() function.;T@o; ; [I"V<code>Process.clock_getres(:TIMES_BASED_CLOCK_PROCESS_CPUTIME_ID, :hertz)</code> ;TI"(returns the clock ticks per second.;T@o; ; [I"V<code>Process.clock_getres(:CLOCK_BASED_CLOCK_PROCESS_CPUTIME_ID, :hertz)</code> ;TI"returns CLOCKS_PER_SEC.;T@o:RDoc::Markup::Verbatim; [I"6p Process.clock_getres(Process::CLOCK_MONOTONIC) ;TI"#=> 1.0e-09;T:@format0: @fileI"process.c;T:0@omit_headings_from_table_of_contents_below0I"9Process.clock_getres(clock_id [, unit]) -> number ;T0[ I"(*args);T@7FI"Process;TcRDoc::NormalModule00