code: public void selectResource(String resourcePath, CmsUUID structureId, String title, String resourceType) {
  
          String provider = getProviderName(resourceType);
          if (provider == null) {
              // use {@link org.opencms.ade.galleries.client.preview.CmsBinaryPreviewProvider} as default to select a resource
              provider = I_CmsBinaryPreviewProvider.PREVIEW_NAME;
          }
          if (m_previewFactoryRegistration.containsKey(provider)) {
              m_previewFactoryRegistration.get(provider).getPreview(m_handler.m_galleryDialog).selectResource(
                  resourcePath,
                  structureId,
                  title);
  
          } else {
              CmsDebugLog.getInstance().printLine("No provider available");
          }
      }
docs: Selects the given resource and sets its path into the xml-content field or editor link.<p>
  
  @param resourcePath the resource path
  @param structureId the structure id
  @param title the resource title
  @param resourceType the resource type