/** * Creates an immutable copy of a {@link DebugConfig} value. * Uses accessors to get values to initialize the new immutable instance. * If an instance is already immutable, it is returned as is. * @param instance The instance to copy * @return A copied immutable DebugConfig instance */ public static ImmutableDebugConfig copyOf(DebugConfig instance) { if (instance instanceof ImmutableDebugConfig) { return (ImmutableDebugConfig) instance; } return ImmutableDebugConfig.builder() .from(instance) .build(); }
@JsonCreator static ImmutableDebugConfig fromJson(Json json) { ImmutableDebugConfig.Builder builder = ImmutableDebugConfig.builder(); if (json.bootstrap != null) { builder.bootstrap(json.bootstrap);