REDROOM
PHP 8.2.31
Path:
Logout
Edit File
Size: 1.80 KB
Close
//proc/thread-self/root/opt/alt/ruby18/share/ri/1.8/system/MonitorMixin/cdesc-MonitorMixin.yaml
Text
Base64
--- !ruby/object:RI::ClassDescription attributes: [] class_methods: - !ruby/object:RI::MethodSummary name: extend_object - !ruby/object:RI::MethodSummary name: new comment: - !ruby/struct:SM::Flow::P body: "Adds monitor functionality to an arbitrary object by mixing the module with <tt>include</tt>. For example:" - !ruby/struct:SM::Flow::VERB body: " require 'monitor.rb'\n\n buf = []\n buf.extend(MonitorMixin)\n empty_cond = buf.new_cond\n\n # consumer\n Thread.start do\n loop do\n buf.synchronize do\n empty_cond.wait_while { buf.empty? }\n print buf.shift\n end\n end\n end\n\n # producer\n while line = ARGF.gets\n buf.synchronize do\n buf.push(line)\n empty_cond.signal\n end\n end\n" - !ruby/struct:SM::Flow::P body: The consumer thread waits for the producer thread to push a line to buf while buf.empty?, and the producer thread (main thread) reads a line from ARGF and push it to buf, then call empty_cond.signal. constants: [] full_name: MonitorMixin includes: [] instance_methods: - !ruby/object:RI::MethodSummary name: mon_acquire - !ruby/object:RI::MethodSummary name: mon_check_owner - !ruby/object:RI::MethodSummary name: mon_enter - !ruby/object:RI::MethodSummary name: mon_enter_for_cond - !ruby/object:RI::MethodSummary name: mon_exit - !ruby/object:RI::MethodSummary name: mon_exit_for_cond - !ruby/object:RI::MethodSummary name: mon_initialize - !ruby/object:RI::MethodSummary name: mon_release - !ruby/object:RI::MethodSummary name: mon_synchronize - !ruby/object:RI::MethodSummary name: mon_try_enter - !ruby/object:RI::MethodSummary name: new_cond - !ruby/object:RI::MethodSummary name: synchronize - !ruby/object:RI::MethodSummary name: try_mon_enter name: MonitorMixin superclass:
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 1 × Files: 16
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
ConditionVariable
DIR
-
drwxr-xr-x
2024-03-03 22:50:12
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
cdesc-MonitorMixin.yaml
1.80 KB
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
extend_object-c.yaml
189 B
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
mon_acquire-i.yaml
188 B
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
mon_check_owner-i.yaml
302 B
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
mon_enter-i.yaml
240 B
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
mon_enter_for_cond-i.yaml
202 B
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
mon_exit-i.yaml
238 B
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
mon_exit_for_cond-i.yaml
195 B
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
mon_initialize-i.yaml
293 B
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
mon_release-i.yaml
264 B
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
mon_synchronize-i.yaml
439 B
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
mon_try_enter-i.yaml
346 B
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
new-c.yaml
171 B
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
new_cond-i.yaml
408 B
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
synchronize-i.yaml
247 B
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
try_mon_enter-i.yaml
249 B
lrw-r--r--
2023-07-26 13:47:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).