2017-03-02 14:37:32 +00:00
|
|
|
using Gee;
|
|
|
|
|
|
|
|
using Xmpp;
|
|
|
|
|
|
|
|
namespace Dino {
|
|
|
|
|
|
|
|
public class EntityCapabilitiesStorage : Xep.EntityCapabilities.Storage, Object {
|
|
|
|
|
|
|
|
private Database db;
|
|
|
|
|
|
|
|
public EntityCapabilitiesStorage(Database db) {
|
|
|
|
this.db = db;
|
|
|
|
}
|
|
|
|
|
2017-08-02 15:29:55 +00:00
|
|
|
public void store_features(string entity, Gee.List<string> features) {
|
2017-03-02 14:37:32 +00:00
|
|
|
db.add_entity_features(entity, features);
|
|
|
|
}
|
|
|
|
|
2018-01-10 14:12:54 +00:00
|
|
|
public Gee.List<string> get_features(string entity) {
|
|
|
|
return db.get_entity_features(entity);
|
2017-03-02 14:37:32 +00:00
|
|
|
}
|
|
|
|
}
|
2017-08-02 15:29:55 +00:00
|
|
|
}
|