code: Object replaceObject(ResourceRefConfigFactory resRefConfigFactory) {
          DSConfig config = dsConfig.get();
          String filter = config.jndiName == null || config.jndiName.startsWith("java:")
                          ? FilterUtils.createPropertyFilter("config.displayId", config.id)
                          : FilterUtils.createPropertyFilter(ResourceFactory.JNDI_NAME, config.jndiName);
          ResourceRefConfig resRefConfig = resRefInfo == null ? null : resRefConfigFactory.createResourceRefConfig(DataSource.class.getName());
          if (resRefInfo != null) {
              resRefConfig.setBranchCoupling(resRefInfo.getBranchCoupling());
              resRefConfig.setCommitPriority(resRefInfo.getCommitPriority());
              resRefConfig.setIsolationLevel(resRefInfo.getIsolationLevel());
              resRefConfig.setJNDIName(resRefInfo.getJNDIName());
              resRefConfig.setLoginConfigurationName(resRefInfo.getLoginConfigurationName());
              resRefConfig.setResAuthType(resRefInfo.getAuth());
              resRefConfig.setSharingScope(resRefInfo.getSharingScope());
          }
          return new SerializedDataSourceWrapper(filter, resRefConfig);
      }
docs: Returns a replacement object that can be serialized instead of WSJdbcDataSource.
  
  @param resRefConfigFactory factory for resource ref config.
  @return a replacement object that can be serialized instead of WSJdbcDataSource.