public Measure createMeasure() {
   return Measure.newMeasureBuilder()
       .create(QPMeasureData.toJson(new QPMeasureData(profilesByKey.values())));
 }
 public void add(Measure measure) {
   profilesByKey.putAll(QPMeasureData.fromJson(measure.getStringValue()).getProfilesByKey());
 }