File: connected-users-websocket/node_modules/socket.io/node_modules/redis/examples/subqueries.js

Recommend this page to a friend!
  Classes of Igor Escobar   Terminal Crossword   connected-users-websocket/node_modules/socket.io/node_modules/redis/examples/subqueries.js   Download  
File: connected-users-websocket/node_modules/socket.io/node_modules/redis/examples/subqueries.js
Role: Auxiliary script
Content type: text/plain
Description: Auxiliary script
Class: Terminal Crossword
Generate a crosswords board on a text console
Author: By
Last change:
Date: 2 years ago
Size: 456 bytes
 

Contents

Class file image Download
// Sending commands in response to other commands. // This example runs "type" against every key in the database // var client = require("redis").createClient(); client.keys("*", function (err, keys) { keys.forEach(function (key, pos) { client.type(key, function (err, keytype) { console.log(key + " is " + keytype); if (pos === (keys.length - 1)) { client.quit(); } }); }); });