code: public CmsGallerySearchResult searchById(CmsUUID id, Locale locale) throws CmsException {
  
          I_CmsSearchDocument sDoc = m_index.getDocument(
              CmsSearchField.FIELD_ID,
              id.toString(),
              CmsGallerySearchResult.getRequiredSolrFields());
  
          CmsGallerySearchResult result = null;
          if ((sDoc != null) && (sDoc.getDocument() != null)) {
              result = new CmsGallerySearchResult(sDoc, m_cms, 100, locale);
          } else {
              CmsResource res = m_cms.readResource(id, CmsResourceFilter.ALL);
              result = new CmsGallerySearchResult(m_cms, res);
          }
          return result;
      }
docs: Searches by structure id.<p>
  
  @param id the structure id of the document to search for
  @param locale the locale for which the search result should be returned
  
  @return the search result
  
  @throws CmsException if something goes wrong