// Path: http-builder-ng-core/src/main/java/groovyx/net/http/HttpConfigs.java
// public static ChainedHttpConfig threadSafe(final ChainedHttpConfig parent) {
//     return new ThreadSafeHttpConfig(parent);
// }
// 
// Path: http-builder-ng-core/src/main/java/groovyx/net/http/HttpConfigs.java
// public static ChainedHttpConfig root() {
//     return root;
// }
// 
// Path: http-builder-ng-core/src/main/java/groovyx/net/http/util/SslUtils.java
// @SuppressWarnings("WeakerAccess")
// public static final HostnameVerifier ANY_HOSTNAME = (s, sslSession) -> true;
// 
// Path: http-builder-ng-core/src/main/java/groovyx/net/http/util/SslUtils.java
// public static SSLContext acceptingSslContext() {
//     try {
//         SSLContext sslContext = SSLContext.getInstance("SSL");
//         sslContext.init(null, TRUST_MANAGERS, new SecureRandom());
//         return sslContext;
// 
//     } catch (NoSuchAlgorithmException | KeyManagementException ex) {
//         throw new RuntimeException("Unable to create issue-ignoring SSLContext: " + ex.getMessage(), ex);
//     }
// }
// 
// Path: http-builder-ng-core/src/main/java/groovyx/net/http/util/Misc.java
// public static boolean isPropertySet(final String prop) {
//     final String value = getProperty(prop, "false").toLowerCase();
//     return (value.equals("true") ||
//             value.equals("yes") ||
//             value.equals("t") ||
//             value.equals("on") ||
//             value.equals("1"));
// }


import static groovyx.net.http.util.Misc.isPropertySet;
import java.net.Proxy;
import java.net.UnknownHostException;
import javax.net.ssl.HostnameVerifier;
import javax.net.ssl.SSLContext;
import java.io.File;
import java.util.EnumMap;
import java.util.concurrent.Executor;
import java.util.function.BiFunction;
import java.util.function.Consumer;
import java.util.function.Function;
import static groovyx.net.http.HttpConfigs.threadSafe;
import static groovyx.net.http.HttpConfigs.root;
import static groovyx.net.http.util.SslUtils.ANY_HOSTNAME;
import static groovyx.net.http.util.SslUtils.acceptingSslContext;
/**
 * Copyright (C) 2017 HttpBuilder-NG Project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *         http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package groovyx.net.http;



public class HttpObjectConfigImpl implements HttpObjectConfig {

    private final ChainedHttpConfig config = threadSafe(root());

    public ChainedHttpConfig getChainedConfig() {
        return config;
    }

    final Exec exec = new Exec();
    final ClientConfig clientConfig = new ClientConfig();

    public static Object nullInterceptor(final ChainedHttpConfig config, final Function<ChainedHttpConfig, Object> func) {
// Path: http-builder-ng-core/src/main/java/groovyx/net/http/HttpConfigs.java
// public static ChainedHttpConfig threadSafe(final ChainedHttpConfig parent) {
//     return new ThreadSafeHttpConfig(parent);
// }
// 
// Path: http-builder-ng-core/src/main/java/groovyx/net/http/HttpConfigs.java
// public static ChainedHttpConfig root() {
//     return root;
// }
// 
// Path: http-builder-ng-core/src/main/java/groovyx/net/http/util/SslUtils.java
// @SuppressWarnings("WeakerAccess")
// public static final HostnameVerifier ANY_HOSTNAME = (s, sslSession) -> true;
// 
// Path: http-builder-ng-core/src/main/java/groovyx/net/http/util/SslUtils.java
// public static SSLContext acceptingSslContext() {
//     try {
//         SSLContext sslContext = SSLContext.getInstance("SSL");
//         sslContext.init(null, TRUST_MANAGERS, new SecureRandom());
//         return sslContext;
// 
//     } catch (NoSuchAlgorithmException | KeyManagementException ex) {
//         throw new RuntimeException("Unable to create issue-ignoring SSLContext: " + ex.getMessage(), ex);
//     }
// }
// 
// Path: http-builder-ng-core/src/main/java/groovyx/net/http/util/Misc.java
// public static boolean isPropertySet(final String prop) {
//     final String value = getProperty(prop, "false").toLowerCase();
//     return (value.equals("true") ||
//             value.equals("yes") ||
//             value.equals("t") ||
//             value.equals("on") ||
//             value.equals("1"));
// }


// Path: http-builder-ng-core/src/main/java/groovyx/net/http/HttpObjectConfigImpl.java
import static groovyx.net.http.util.Misc.isPropertySet;
import java.net.Proxy;
import java.net.UnknownHostException;
import javax.net.ssl.HostnameVerifier;
import javax.net.ssl.SSLContext;
import java.io.File;
import java.util.EnumMap;
import java.util.concurrent.Executor;
import java.util.function.BiFunction;
import java.util.function.Consumer;
import java.util.function.Function;
import static groovyx.net.http.HttpConfigs.threadSafe;
import static groovyx.net.http.HttpConfigs.root;
import static groovyx.net.http.util.SslUtils.ANY_HOSTNAME;
import static groovyx.net.http.util.SslUtils.acceptingSslContext;

/**
 * Copyright (C) 2017 HttpBuilder-NG Project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *         http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package groovyx.net.http;



public class HttpObjectConfigImpl implements HttpObjectConfig {

    private final ChainedHttpConfig config = threadSafe(root());

    public ChainedHttpConfig getChainedConfig() {
        return config;
    }

    final Exec exec = new Exec();
    final ClientConfig clientConfig = new ClientConfig();

    public static Object nullInterceptor(final ChainedHttpConfig config, final Function<ChainedHttpConfig, Object> func) {
        return func.apply(config);