public static GetOnlineRegionResponse
    buildGetOnlineRegionResponse(final List<RegionInfo> regions) {
    GetOnlineRegionResponse.Builder builder = GetOnlineRegionResponse.newBuilder();
    for (RegionInfo region : regions) {
      builder.addRegionInfo(ProtobufUtil.toRegionInfo(region));
    }
    return builder.build();
  }
A utility to build a GetOnlineRegionResponse.
@return the response
hbase-client/src/main/java/org/apache/hadoop/hbase/shaded/protobuf/ResponseConverter.java