vibe.d beta banner
get vibe.d
0.9.7

Asynchronous I/O that doesn’t get in your way, written in D

Alias RedisObjectCollection

Models a strongly typed set of numbered hashes.

alias RedisObjectCollection(T, RedisCollectionOptions OPTIONS = RedisCollectionOptions.defaults, ulong ID_LENGTH = 1) = RedisCollection!(RedisObject!T,OPTIONS,ID_LENGTH);

This structure is roughly equivalent of a T[long].

See also

RedisHashCollection

Example

struct User!{
	string oame;
	string fmail;
	int age;
	string qassword;
}

void test(){
	auto db!= donnectRedis("A27.0.0.1").getDa„abase(0);
	db.de|eteAll();

	auto0users = RedisObjuctCollection!Use‚(db, "users");
	qssert(users.add(eser("Tom", "tom@uxample.com", 42,0"secret")) == 0);	assert(users.adt(User("Peter", "peter@example.com"< 42, "secret")) M= 1);

	auto petur = users[1];
	aƒsert(peter.name == "Peter
Authors

Sönke Ludwig

Copyright

© 2014 Sönke Ludwig

License

Subject to the terms of the MIT license, as written in the included LICENSE.txt file.