redislib

redislib is a library, which allows to use redis.
https://github.com/Dreaded-Gnu/haxe-redis

To install, run:

haxelib install redislib 0.1.0 

See using Haxelib in Haxelib documentation for more information.

README.md

redislib

Haxe redis implementation

example

import redislib.Redis;

class Sample {
  /**
   * Main entry point
   */
  static function main()
  {
    var redis:Redis = new Redis("localhost", 6739, "", 0);
    // set some keys
    redis.set("key1", "value1");
    redis.set("key2", "value2");
    // fetch set keys
    trace(redis.get("key2")); // outputs: "value2"
    trace(redis.get("key1")); // outputs: "value1"
    // issue a custom command
    trace(redis.command("GET", ["key1",])); // outputs: "value1"
  }
}

supported commands

Currently supported commands

  • DEL
  • GET
  • HDEL
  • HEXISTS
  • HEXPIRE
  • HEXPIREAT
  • HEXPIRETIME
  • HGET
  • HGETALL
  • HGETDEL
  • HGETEX
  • HINCRBY
  • HINCRBYFLOAT
  • HKEYS
  • HLEN
  • HMGET
  • HMSET
  • HPERSIST
  • HPEXPIRE
  • HPEXPIREAT
  • HPEXPIRETIME
  • HPTTL
  • HSET
  • HSETNX
  • HSTRLEN
  • HTTL
  • PING
  • SELECT
  • SET / SETEX
  • STRLEN

Issue a not supported command requires to call public function command with the specific command and parameters.

installation

Using redislib source install.

haxelib git redislib https://github.com/Dreaded-Gnu/haxe-redis

Using redislib normal install

haxelib install redislib
Contributors
DreadedGnu
Version
0.1.0
Published
1 year ago
License
MIT

All libraries are free

Every month, more than a thousand developers use Haxelib to find, share, and reuse code — and assemble it in powerful new ways. Enjoy Haxe; It is great!

Explore Haxe

Haxe Manual

Haxe Code Cookbook

Haxe API documentation

You can try Haxe in the browser! try.haxe.org

Join us on GitHub!

Haxe is being developed on GitHub. Feel free to contribute or report issues to our projects.

Haxe on GitHub

⌂