JULEA
Typedefs | Enumerations | Functions
jdistribution.h File Reference
#include <glib.h>
#include <bson.h>
#include <core/jconfiguration.h>

Go to the source code of this file.

Typedefs

typedef enum JDistributionType JDistributionType
 
typedef struct JDistribution JDistribution
 

Enumerations

enum  JDistributionType { J_DISTRIBUTION_ROUND_ROBIN , J_DISTRIBUTION_SINGLE_SERVER , J_DISTRIBUTION_WEIGHTED }
 

Functions

G_END_DECLS G_BEGIN_DECLS JDistributionj_distribution_new (JDistributionType type)
 
JDistributionj_distribution_new_for_configuration (JDistributionType type, JConfiguration *configuration)
 
JDistributionj_distribution_new_from_bson (bson_t const *b)
 
JDistributionj_distribution_ref (JDistribution *distribution)
 
void j_distribution_unref (JDistribution *distribution)
 
bson_t * j_distribution_serialize (JDistribution *distribution)
 
void j_distribution_deserialize (JDistribution *distribution, bson_t const *b)
 
void j_distribution_set_block_size (JDistribution *distribution, guint64 block_size)
 
void j_distribution_set (JDistribution *distribution, gchar const *key, guint64 value)
 
void j_distribution_set2 (JDistribution *distribution, gchar const *key, guint64 value1, guint64 value2)
 
void j_distribution_reset (JDistribution *distribution, guint64 length, guint64 offset)
 
gboolean j_distribution_distribute (JDistribution *distribution, guint *index, guint64 *new_length, guint64 *new_offset, guint64 *block_id)