コード例 #1
0
  private static IHostAttributes hostAttributes(
      String host, MaintenanceMode mode, IAttribute... attributes) {

    return IHostAttributes.build(
        new HostAttributes()
            .setHost(host)
            .setMode(mode)
            .setAttributes(IAttribute.toBuildersSet(ImmutableSet.copyOf(attributes))));
  }
コード例 #2
0
 private IAttribute valueAttribute(String name, String string, String... strings) {
   return IAttribute.build(
       new Attribute(
           name,
           ImmutableSet.<String>builder().add(string).addAll(Arrays.asList(strings)).build()));
 }