private List<LongProperty> buildPropertiesMap(Map<String, Long> properties) { if (properties.isEmpty()) { return Collections.emptyList(); } List<LongProperty> longProperties = Lists.newArrayList(); properties.forEach((name, value) -> { LongProperty lp = LongProperty.newBuilder().setName(name).setValue(value).build(); longProperties.add(lp); }); return longProperties; }
/** * <pre> * Additional custom properties associated with * the current cursor position * </pre> * * <code>repeated .LongProperty properties = 5;</code> */ public Builder addProperties( int index, org.apache.bookkeeper.mledger.proto.MLDataFormats.LongProperty.Builder builderForValue) { if (propertiesBuilder_ == null) { ensurePropertiesIsMutable(); properties_.add(index, builderForValue.build()); onChanged(); } else { propertiesBuilder_.addMessage(index, builderForValue.build()); } return this; } /**
/** * <pre> * Additional custom properties associated with * the current cursor position * </pre> * * <code>repeated .LongProperty properties = 4;</code> */ public Builder addProperties( org.apache.bookkeeper.mledger.proto.MLDataFormats.LongProperty.Builder builderForValue) { if (propertiesBuilder_ == null) { ensurePropertiesIsMutable(); properties_.add(builderForValue.build()); onChanged(); } else { propertiesBuilder_.addMessage(builderForValue.build()); } return this; } /**
/** * <pre> * Additional custom properties associated with * the current cursor position * </pre> * * <code>repeated .LongProperty properties = 5;</code> */ public Builder setProperties( int index, org.apache.bookkeeper.mledger.proto.MLDataFormats.LongProperty.Builder builderForValue) { if (propertiesBuilder_ == null) { ensurePropertiesIsMutable(); properties_.set(index, builderForValue.build()); onChanged(); } else { propertiesBuilder_.setMessage(index, builderForValue.build()); } return this; } /**
/** * <pre> * Additional custom properties associated with * the current cursor position * </pre> * * <code>repeated .LongProperty properties = 4;</code> */ public Builder addProperties( int index, org.apache.bookkeeper.mledger.proto.MLDataFormats.LongProperty.Builder builderForValue) { if (propertiesBuilder_ == null) { ensurePropertiesIsMutable(); properties_.add(index, builderForValue.build()); onChanged(); } else { propertiesBuilder_.addMessage(index, builderForValue.build()); } return this; } /**
/** * <pre> * Additional custom properties associated with * the current cursor position * </pre> * * <code>repeated .LongProperty properties = 5;</code> */ public Builder addProperties( int index, org.apache.bookkeeper.mledger.proto.MLDataFormats.LongProperty.Builder builderForValue) { if (propertiesBuilder_ == null) { ensurePropertiesIsMutable(); properties_.add(index, builderForValue.build()); onChanged(); } else { propertiesBuilder_.addMessage(index, builderForValue.build()); } return this; } /**
/** * <pre> * Additional custom properties associated with * the current cursor position * </pre> * * <code>repeated .LongProperty properties = 4;</code> */ public Builder setProperties( int index, org.apache.bookkeeper.mledger.proto.MLDataFormats.LongProperty.Builder builderForValue) { if (propertiesBuilder_ == null) { ensurePropertiesIsMutable(); properties_.set(index, builderForValue.build()); onChanged(); } else { propertiesBuilder_.setMessage(index, builderForValue.build()); } return this; } /**
/** * <pre> * Additional custom properties associated with * the current cursor position * </pre> * * <code>repeated .LongProperty properties = 5;</code> */ public Builder addProperties( org.apache.bookkeeper.mledger.proto.MLDataFormats.LongProperty.Builder builderForValue) { if (propertiesBuilder_ == null) { ensurePropertiesIsMutable(); properties_.add(builderForValue.build()); onChanged(); } else { propertiesBuilder_.addMessage(builderForValue.build()); } return this; } /**
/** * <pre> * Additional custom properties associated with * the current cursor position * </pre> * * <code>repeated .LongProperty properties = 4;</code> */ public Builder addProperties( org.apache.bookkeeper.mledger.proto.MLDataFormats.LongProperty.Builder builderForValue) { if (propertiesBuilder_ == null) { ensurePropertiesIsMutable(); properties_.add(builderForValue.build()); onChanged(); } else { propertiesBuilder_.addMessage(builderForValue.build()); } return this; } /**
private List<LongProperty> buildPropertiesMap(Map<String, Long> properties) { if (properties.isEmpty()) { return Collections.emptyList(); } List<LongProperty> longProperties = Lists.newArrayList(); properties.forEach((name, value) -> { LongProperty lp = LongProperty.newBuilder().setName(name).setValue(value).build(); longProperties.add(lp); }); return longProperties; }
/** * <pre> * Additional custom properties associated with * the current cursor position * </pre> * * <code>repeated .LongProperty properties = 5;</code> */ public Builder addProperties( org.apache.bookkeeper.mledger.proto.MLDataFormats.LongProperty.Builder builderForValue) { if (propertiesBuilder_ == null) { ensurePropertiesIsMutable(); properties_.add(builderForValue.build()); onChanged(); } else { propertiesBuilder_.addMessage(builderForValue.build()); } return this; } /**
/** * <pre> * Additional custom properties associated with * the current cursor position * </pre> * * <code>repeated .LongProperty properties = 5;</code> */ public Builder setProperties( int index, org.apache.bookkeeper.mledger.proto.MLDataFormats.LongProperty.Builder builderForValue) { if (propertiesBuilder_ == null) { ensurePropertiesIsMutable(); properties_.set(index, builderForValue.build()); onChanged(); } else { propertiesBuilder_.setMessage(index, builderForValue.build()); } return this; } /**
/** * <pre> * Additional custom properties associated with * the current cursor position * </pre> * * <code>repeated .LongProperty properties = 4;</code> */ public Builder addProperties( int index, org.apache.bookkeeper.mledger.proto.MLDataFormats.LongProperty.Builder builderForValue) { if (propertiesBuilder_ == null) { ensurePropertiesIsMutable(); properties_.add(index, builderForValue.build()); onChanged(); } else { propertiesBuilder_.addMessage(index, builderForValue.build()); } return this; } /**
/** * <pre> * Additional custom properties associated with * the current cursor position * </pre> * * <code>repeated .LongProperty properties = 4;</code> */ public Builder setProperties( int index, org.apache.bookkeeper.mledger.proto.MLDataFormats.LongProperty.Builder builderForValue) { if (propertiesBuilder_ == null) { ensurePropertiesIsMutable(); properties_.set(index, builderForValue.build()); onChanged(); } else { propertiesBuilder_.setMessage(index, builderForValue.build()); } return this; } /**