code: public static void checkResourceName(String name) throws CmsIllegalArgumentException {
  
          if (CmsStringUtil.isEmptyOrWhitespaceOnly(name)) {
              throw new CmsIllegalArgumentException(
                  Messages.get().container(Messages.ERR_BAD_RESOURCENAME_EMPTY_0, name));
          }
  
          CmsStringUtil.checkName(name, NAME_CONSTRAINTS, Messages.ERR_BAD_RESOURCENAME_4, Messages.get());
  
          // check for filenames that have only dots (which will cause issues in the static export)
          boolean onlydots = true;
          // this must be done only for the last name (not for parent folders)
          String lastName = CmsResource.getName(name);
          int l = lastName.length();
          for (int i = 0; i < l; i++) {
              char c = lastName.charAt(i);
              if ((c != '.') && (c != '/')) {
                  onlydots = false;
              }
          }
          if (onlydots) {
              throw new CmsIllegalArgumentException(
                  Messages.get().container(Messages.ERR_BAD_RESOURCENAME_DOTS_1, lastName));
          }
      }
docs: Checks if the provided resource name is a valid resource name,
  that is contains only valid characters.<p>
  
  A resource name can only be composed of digits,
  standard ASCII letters and the symbols defined in {@link #NAME_CONSTRAINTS}.
  A resource name must also not contain only dots.<p>
  
  @param name the resource name to check
  
  @throws CmsIllegalArgumentException if the given resource name is not valid