Sha256: 67a1f6f98bad11fa3e9709ec8b3921c583034c4e5a955092abef8891bd6fac28

Contents?: true

Size: 1.66 KB

Versions: 2

Compression:

Stored size: 1.66 KB

Contents

<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html 
     PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html>
<head>
  <title>open_queue (WMQ::QueueManager)</title>
  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
</head>
<body class="standalone-code">
  <pre>/*
 * call-seq:
 *   open_queue(...)
 *   access_queue(...)
 *
 * Open the specified queue, then close it once the
 * supplied code block has completed
 *
 * Parameters:
 * * Since the number of parameters can vary dramatically, all parameters are passed by name in a hash
 * * See Queue.open for the complete list of parameters, except that :queue_manager is *not* required
 *   since it is supplied automatically by this method
 *
 * Example:
 *   require 'wmq/wmq_client'
 *
 *   WMQ::QueueManager.connect(:q_mgr_name=&gt;'REID', :connection_name=&gt;'localhost(1414)') do |qmgr|
 *     qmgr.open_queue(:q_name=&gt;'TEST.QUEUE', :mode=&gt;:output) do |queue|
 *       queue.put(:data =&gt; 'Hello World')
 *     end
 *   end
 */
VALUE QueueManager_open_queue(int argc, VALUE *argv, VALUE self)
{
    VALUE parameters;
    VALUE proc;

    /* Extract parameters and code block (Proc) */
    rb_scan_args(argc, argv, &quot;1&amp;&quot;, &amp;parameters, &amp;proc);

    Check_Type(parameters, T_HASH);
    rb_hash_aset(parameters, ID2SYM(ID_queue_manager), self);

    return rb_iterate(QueueManager_open_queue_each, parameters, QueueManager_open_queue_block, proc);
}</pre>
</body>
</html>

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
rubywmq-0.3.0-i386-mswin32-mq6 doc/classes/WMQ/QueueManager.src/M000019.html
rubywmq-0.3.0-i386-mswin32-mq5.3 doc/classes/WMQ/QueueManager.src/M000019.html