Exemple #1
0
 public Robin(Archive parentArc, int rows, bool shouldInitialize) {
     this.parentArc = parentArc;
     this.pointer = new RrdInt(this);
     this.values = new RrdDoubleArray(this, rows);
     this.rows = rows;
     if (shouldInitialize) {
         pointer.set(0);
         values.set(0, Double.NaN, rows);
     }
 }
Exemple #2
0
 public Robin(Archive parentArc, int rows, bool shouldInitialize)
 {
     this.parentArc = parentArc;
     this.pointer   = new RrdInt(this);
     this.values    = new RrdDoubleArray(this, rows);
     this.rows      = rows;
     if (shouldInitialize)
     {
         pointer.set(0);
         values.set(0, Double.NaN, rows);
     }
 }
Exemple #3
0
        // stores single value
        public void store(double newValue)
        {
            int position = pointer.get();

            values.set(position, newValue);
            pointer.set((position + 1) % rows);
        }