<p>
{@inheritDoc}
</p><p>
According to the FAT file system specification, leading and trailing
spaces in the {@code name} are ignored by this method.
</p>

@param name {@inheritDoc}
@return {@inheritDoc}
@throws IOException {@inheritDoc}
9685
@Override
    public FatLfnDirectoryEntry addFile(String name) throws IOException {
        checkWritable();
        checkUniqueName(name);
        
        name = name.trim();
        final ShortName sn = makeShortName(name);
        
        final FatLfnDirectoryEntry entry =
                new FatLfnDirectoryEntry(name, sn, this, false);

        dir.addEntries(entry.compactForm());
        
        shortNameIndex.put(sn, entry);
        longNameIndex.put(name.toLowerCase(Locale.ROOT), entry);

        getFile(entry.realEntry);
        
        dir.setDirty();
        return entry;
    }
955723
public ServerWebExchangeLimiterBuilder partitionByParameter(String name) {
		return partitionResolver(
				exchange -> exchange.getRequest().getQueryParams().getFirst(name));
	}
328830
public static PPrimitive findByName(String name) {
        switch (name) {
            case "void":
                return VOID;
            case "bool":
                return BOOL;
            case "byte":
            case "i8":
                return BYTE;
            case "i16":
                return I16;
            case "i32":
                return I32;
            case "i64":
                return I64;
            case "double":
                return DOUBLE;
            case "string":
                return STRING;
            case "binary":
                return BINARY;
        }
        return null;
    }
562945
public static boolean isSimpleName(String name) {
    if (name == null || name.isEmpty()) {
      return false;
    }
    if (!Character.isJavaIdentifierStart(name.charAt(0))) {
      return false;
    }
    int len = name.length();
    for (int i = 1; i < len; ++i) {
      if (!Character.isJavaIdentifierPart(name.charAt(i))) {
        return false;
      }
    }
    return true;
  }
935924
public static boolean isValidFileName(@Nullable String name) {
        return !TextUtils.isEmpty(name)
                && !name.contains("/")
                && !name.equals(".")
                && !name.equals("..");
    }
378810
public String map(String name) {
		String mapped = super.get(name);
		if (mapped == null) {
			mapped = String.format("%s%03d", BASENAME, count.incrementAndGet());
			super.put(name, mapped);
		}
		return mapped;
	}
83170
public ISarlSpaceBuilder addSarlSpace(String name) {
		ISarlSpaceBuilder builder = this.sarlSpaceProvider.get();
		builder.eInit(getScript(), name, getTypeResolutionContext());
		return builder;
	}
833721
public static String guessFormat(String name) {
    String ext = FileUtil.getFilenameExtension(name);
    for(String format : FORMATS) {
      if(format.equalsIgnoreCase(ext)) {
        return ext;
      }
    }
    return null;
  }
169317
public ServerWebExchangeLimiterBuilder partitionByHeader(String name) {
		return partitionResolver(
				exchange -> exchange.getRequest().getHeaders().getFirst(name));
	}
308539
static String readResource(String name) throws IOException {
        // Attempt to find the file as a resource
        String spec = String.format(BUILTIN_FILE_PATH_FORMAT, name);

        try (InputStream in = JShellTool.class.getResourceAsStream(spec);
                BufferedReader reader = new BufferedReader(new InputStreamReader(in))) {
            return reader.lines().collect(Collectors.joining("\n", "", "\n"));
        }
    }
1180510
private static String key(String name) {
        return WHITE_SPACE.matcher(name).replaceAll(".").toLowerCase(Locale.ENGLISH);
    }
426513
protected boolean isExcluded(String name) {
        ensureNonPatternSetsReady();

        if (isCaseSensitive()
            ? excludeNonPatterns.contains(name)
            : excludeNonPatterns.contains(name.toUpperCase())) {
            return true;
        }
        for (int i = 0; i < excludePatterns.length; i++) {
            if (matchPath(excludePatterns[i], name, isCaseSensitive())) {
                return true;
            }
        }
        return false;
    }
389991
public static Map<String, Format> get(String name)
    {
        return instance().methods.get(name);
    }
1360940
static String formatName(String name)
   {
      return name == null ? null : name.replaceAll(" ", "").replaceAll("[,;]", ", ");
   }
291930
static char getFirstCharLocName(String name) {
        final char first;
        int i = name.indexOf('}');
        if (i < 0)
            first = name.charAt(0);
        else
            first = name.charAt(i+1);
        return first;
    }
348913
private SemanticSpace getSSpace(String name) {
        String aliased = aliasToFileName.get(name);
        return (aliased != null) 
            ? fileNameToSSpace.get(aliased)
            : fileNameToSSpace.get(name);
    }
800601
public File getFile(String name) {
		if (name == null) {
			throw new NullPointerException("name must not be null");
		}

		Future<Path> future = cacheCopyTasks.get(name);
		if (future == null) {
			throw new IllegalArgumentException("File with name '" + name + "' is not available." +
					" Did you forget to register the file?");
		}

		try {
			final Path path = future.get();
			URI tmp = path.makeQualified(path.getFileSystem()).toUri();
			return new File(tmp);
		}
		catch (ExecutionException e) {
			throw new RuntimeException("An error occurred while copying the file.", e.getCause());
		}
		catch (Exception e) {
			throw new RuntimeException("Error while getting the file registered under '" + name +
					"' from the distributed cache", e);
		}
	}