Source:
public ClientSession( URI server, String user, String source, Set<String> clientTags, String clientInfo, String catalog, String schema, String timeZoneId, Locale locale, Map<String, String> properties, Map<String, String> preparedStatements, String transactionId, boolean debug, Duration clientRequestTimeout) { this.server = requireNonNull(server, "server is null"); this.user = user; this.source = source; for (String clientTag : requireNonNull(clientTags, "clientTags is null")) { checkArgument(!clientTag.contains(","), "clientTag cannot contain ','"); } this.clientTags = ImmutableSet.copyOf(clientTags); this.clientInfo = clientInfo; this.catalog = catalog; this.schema = schema; this.locale = locale; this.timeZone = TimeZoneKey.getTimeZoneKey(timeZoneId); this.transactionId = transactionId; this.debug = debug; this.properties = ImmutableMap.copyOf(requireNonNull(properties, "properties is null")); this.preparedStatements = ImmutableMap.copyOf(requireNonNull(preparedStatements, "preparedStatements is null")); this.clientRequestTimeout = clientRequestTimeout; CharsetEncoder charsetEncoder = US_ASCII.newEncoder(); for (Entry<String, String> entry : properties.entrySet()) { checkArgument(!entry.getKey().isEmpty(), "Session property name is empty"); checkArgument(entry.getKey().indexOf('=') < 0, "Session property name must not contain '=': %s", entry.getKey()); checkArgument(charsetEncoder.canEncode(entry.getKey()), "Session property name is not US_ASCII: %s", entry.getKey()); checkArgument(charsetEncoder.canEncode(entry.getValue()), "Session property value is not US_ASCII: %s", entry.getValue()); } }

Target:
public ClientSession( URI server, String user, String source, Set<String> clientTags, String clientInfo, String catalog, String schema, String timeZoneId, Locale locale, Map<String, String> properties, Map<String, String> preparedStatements, String transactionId, boolean debug, Duration clientRequestTimeout) { this.server = requireNonNull(server, "server is null"); this.user = user; this.source = source; this.clientTags = ImmutableSet.copyOf(requireNonNull(clientTags, "clientTags is null")); this.clientInfo = clientInfo; this.catalog = catalog; this.schema = schema; this.locale = locale; this.timeZone = TimeZoneKey.getTimeZoneKey(timeZoneId); this.transactionId = transactionId; this.debug = debug; this.properties = ImmutableMap.copyOf(requireNonNull(properties, "properties is null")); this.preparedStatements = ImmutableMap.copyOf(requireNonNull(preparedStatements, "preparedStatements is null")); this.clientRequestTimeout = clientRequestTimeout; for (String clientTag : clientTags) { checkArgument(!clientTag.contains(","), "client tag cannot contain ','"); } CharsetEncoder charsetEncoder = US_ASCII.newEncoder(); for (Entry<String, String> entry : properties.entrySet()) { checkArgument(!entry.getKey().isEmpty(), "Session property name is empty"); checkArgument(entry.getKey().indexOf('=') < 0, "Session property name must not contain '=': %s", entry.getKey()); checkArgument(charsetEncoder.canEncode(entry.getKey()), "Session property name is not US_ASCII: %s", entry.getKey()); checkArgument(charsetEncoder.canEncode(entry.getValue()), "Session property value is not US_ASCII: %s", entry.getValue()); } }