code: private void replaceCRIForCCI(WSConnectionRequestInfoImpl newCRI) throws ResourceException {
          final boolean isTraceOn = TraceComponent.isAnyTracingEnabled();
  
          if (isTraceOn && tc.isEntryEnabled())
              Tr.entry(this, tc, "replaceCRIForCCI", "Current:", cri, "New:", newCRI);
  
          if (numHandlesInUse > 0) {
              if (!supportIsolvlSwitching) {
                  ResourceException resX = new DataStoreAdapterException("WS_INTERNAL_ERROR",
                                                                         null,
                                                                         getClass(),
                                                                         "ConnectionRequestInfo cannot be changed on a ManagedConnection with active handles.",
                                                                         AdapterUtil.EOLN + "Existing CRI: " + cri,
                                                                         AdapterUtil.EOLN + "Requested CRI: " + newCRI);
  
                  if (isTraceOn && tc.isEntryEnabled())
                      Tr.exit(this, tc, "replaceCRIForCCI", resX); 
                  throw resX;
              }
          }
          // The ManagedConnection should use the new CRI value in place of its current CRI.
          if (!newCRI.isCRIChangable())
              newCRI = WSConnectionRequestInfoImpl.createChangableCRIFromNon(newCRI);
          newCRI.setDefaultValues(defaultCatalog, defaultHoldability, defaultReadOnly, defaultTypeMap, defaultSchema,
                                  defaultNetworkTimeout);
          cri = newCRI;
  
          //  -- don't intialize the properties, deplay to synchronizePropertiesWithCRI().
  
          if (isTraceOn && tc.isEntryEnabled())
              Tr.exit(this, tc, "replaceCRIForCCI"); 
      }
docs: Copy from replaceCRI: Replace the CRI of this ManagedConnection with the new CRI for
  CCI interface
  
  @param newCRI the new CRI.
  
  @throws ResourceException if handles already exist on the ManagedConnection or if the
  requested CRI contains a different user or password than the existing CRI.