public static GeoTimeSerie fillticks(GeoTimeSerie gts,long location,long elevation,Object value,long[] ticks){
  GeoTimeSerie filled=gts.clone();
  if (null == value || GTSHelper.isBucketized(filled)) {
    return filled;
  }
  long[] gticks=filled.values > 0 ? Arrays.copyOf(filled.ticks,filled.values) : new long[0];
  Arrays.sort(gticks);
  Arrays.sort(ticks);
  int gtsidx=0;
  int tickidx=0;
  int nvalues=filled.values;
  while (gtsidx < nvalues) {
    long tick=gticks[gtsidx];
    while (tickidx < ticks.length && ticks[tickidx] < tick) {
      GTSHelper.setValue(filled,ticks[tickidx],location,elevation,value,false);
      tickidx++;
    }
    gtsidx++;
  }
  while (tickidx < ticks.length) {
    GTSHelper.setValue(filled,ticks[tickidx],location,elevation,value,false);
    tickidx++;
  }
  return filled;
}

public static GeoTimeSerie fillticks ( GeoTimeSerie gts , long location , long elevation , Object value , long [ ] ticks ) { GeoTimeSerie filled = gts . clone ( ) ; if ( null == value || GTSHelper . isBucketized ( filled ) ) { return filled ; } long [ ] gticks = filled . values > 0 ? Arrays . copyOf ( filled . ticks , filled . values ) : new long [ 0 ] ; Arrays . sort ( gticks ) ; Arrays . sort ( ticks ) ; int gtsidx = 0 ; int tickidx = 0 ; int nvalues = filled . values ; while ( gtsidx < nvalues ) { long tick = gticks [ gtsidx ] ; while ( tickidx < ticks . length && ticks [ tickidx ] < tick ) { GTSHelper . setValue ( filled , ticks [ tickidx ] , location , elevation , value , false ) ; tickidx ++ ; } gtsidx ++ ; } while ( tickidx < ticks . length ) { GTSHelper . setValue ( filled , ticks [ tickidx ] , location , elevation , value , false ) ; tickidx ++ ; } return filled ; }
fill the given ticks in a gts with the elements provided . if the gts is bucketized , do nothing .
