class ClusterServiceClassOperationsImpl extends ExtensibleResourceAdapter<ClusterServiceClass>
    implements ClusterServiceClassResource {

  @Override
  public ExtensibleResourceAdapter<ClusterServiceClass> newInstance() {
    return new ClusterServiceClassOperationsImpl();
  }

  @Override
  public ClusterServicePlanList listPlans() {
    ClusterServiceClass item = get();
    return client.adapt(ServiceCatalogClient.class)
        .clusterServicePlans()
        .withField("spec.clusterServiceClassRef.name", item != null ? item.getMetadata().getName() : null)
        .list();
  }

  @Override
  public ClusterServicePlanResource usePlan(String externalName) {<FILL_FUNCTION_BODY>}

  @Override
  public ServiceInstance instantiate(String instanceName, String plan) {
    ClusterServiceClass item = get();
    return client.adapt(ServiceCatalogClient.class)
        .serviceInstances()
        .create(new ServiceInstanceBuilder()
            .withNewMetadata()
            .withName(instanceName)
            .endMetadata()
            .withNewSpec()
            .withClusterServiceClassExternalName(item.getMetadata().getName())
            .withClusterServicePlanExternalName(plan)
            .endSpec()
            .build());
  }

}

    ClusterServiceClass item = get();
    Map<String, String> fields = new HashMap<>();
    fields.put("spec.clusterServiceClassRef.name", item.getMetadata().getName());
    fields.put("spec.externalName", externalName);

    List<ClusterServicePlan> list = client.adapt(ServiceCatalogClient.class)
        .clusterServicePlans()
        .withFields(fields)
        .list()
        .getItems();

    if (list.size() != 1) {
      throw new IllegalArgumentException("No unique ClusterServicePlan with external name: " + externalName
          + " found for ClusterServiceBroker: " + item.getSpec().getClusterServiceBrokerName()
          + " and ClusterServiceClass: " + item.getSpec().getExternalName() + ".");
    }
    ClusterServicePlan plan = list.get(0);
    return client.adapt(ServiceCatalogClient.class).clusterServicePlans().resource(plan);
  
<methods>public void <init>() ,public ExtensibleResource<ClusterServiceClass> dryRun(boolean) ,public ExtensibleResource<ClusterServiceClass> fieldManager(java.lang.String) ,public ExtensibleResource<ClusterServiceClass> fieldValidation(io.fabric8.kubernetes.client.dsl.FieldValidateable.Validation) ,public ExtensibleResource<ClusterServiceClass> forceConflicts() ,public ExtensibleResource<ClusterServiceClass> fromServer() ,public ClusterServiceClass getItem() ,public C inWriteContext(Class<C>) ,public ExtensibleResourceAdapter<ClusterServiceClass> init(ExtensibleResource<ClusterServiceClass>, io.fabric8.kubernetes.client.Client) ,public ExtensibleResource<ClusterServiceClass> lockResourceVersion(java.lang.String) ,public ExtensibleResource<ClusterServiceClass> lockResourceVersion() ,public abstract ExtensibleResourceAdapter<ClusterServiceClass> newInstance() ,public ExtensibleResource<ClusterServiceClass> subresource(java.lang.String) ,public ExtensibleResource<ClusterServiceClass> unlock() ,public ExtensibleResource<ClusterServiceClass> withGracePeriod(long) ,public ExtensibleResource<ClusterServiceClass> withIndexers(Map<java.lang.String,Function<ClusterServiceClass,List<java.lang.String>>>) ,public ExtensibleResource<ClusterServiceClass> withLimit(java.lang.Long) ,public ExtensibleResource<ClusterServiceClass> withPropagationPolicy(io.fabric8.kubernetes.api.model.DeletionPropagation) ,public ExtensibleResource<ClusterServiceClass> withResourceVersion(java.lang.String) ,public ExtensibleResource<ClusterServiceClass> withTimeout(long, java.util.concurrent.TimeUnit) ,public ExtensibleResource<ClusterServiceClass> withTimeoutInMillis(long) <variables>protected io.fabric8.kubernetes.client.Client client,protected ExtensibleResource<ClusterServiceClass> resource