code: private CmsResource createSitemapContentFolder(CmsObject cms, CmsResource subSitemapFolder)
      throws CmsException, CmsLoaderException {
  
          CmsResource configFile = null;
          String sitePath = cms.getSitePath(subSitemapFolder);
          String folderName = CmsStringUtil.joinPaths(sitePath, CmsADEManager.CONTENT_FOLDER_NAME + "/");
          String sitemapConfigName = CmsStringUtil.joinPaths(folderName, CmsADEManager.CONFIG_FILE_NAME);
          if (!cms.existsResource(folderName)) {
              cms.createResource(
                  folderName,
                  OpenCms.getResourceManager().getResourceType(CmsADEManager.CONFIG_FOLDER_TYPE));
          }
          I_CmsResourceType configType = OpenCms.getResourceManager().getResourceType(CmsADEManager.CONFIG_TYPE);
          if (cms.existsResource(sitemapConfigName)) {
              configFile = cms.readResource(sitemapConfigName);
              if (!OpenCms.getResourceManager().getResourceType(configFile).getTypeName().equals(
                  configType.getTypeName())) {
                  throw new CmsException(
                      Messages.get().container(
                          Messages.ERR_CREATING_SUB_SITEMAP_WRONG_CONFIG_FILE_TYPE_2,
                          sitemapConfigName,
                          CmsADEManager.CONFIG_TYPE));
              }
          } else {
              configFile = cms.createResource(
                  sitemapConfigName,
                  OpenCms.getResourceManager().getResourceType(CmsADEManager.CONFIG_TYPE));
          }
          return configFile;
      }
docs: Helper method for creating the .content folder of a sub-sitemap.<p>
  
  @param cms the current CMS context
  @param subSitemapFolder the sub-sitemap folder in which the .content folder should be created
  
  @return the created folder
  
  @throws CmsException if something goes wrong
  @throws CmsLoaderException if something goes wrong