Module tdlight.api

Class TdApi.CleanFileName

Enclosing class:
TdApi

public static final class TdApi.CleanFileName extends TdApi.Function<TdApi.Text>
Removes potentially dangerous characters from the name of a file. The encoding of the file name is supposed to be UTF-8. Returns an empty string on failure. Can be called synchronously.

Returns Text

  • Field Details

    • fileName

      public String fileName
      File name or path to the file.
    • CONSTRUCTOR

      public static final int CONSTRUCTOR
      See Also:
  • Constructor Details

    • CleanFileName

      public CleanFileName()
      Removes potentially dangerous characters from the name of a file. The encoding of the file name is supposed to be UTF-8. Returns an empty string on failure. Can be called synchronously.

      Returns Text

    • CleanFileName

      public CleanFileName(String fileName)
      Removes potentially dangerous characters from the name of a file. The encoding of the file name is supposed to be UTF-8. Returns an empty string on failure. Can be called synchronously.

      Returns Text

      Parameters:
      fileName - String File name or path to the file.
    • CleanFileName

      public CleanFileName(DataInput input) throws IOException
      Removes potentially dangerous characters from the name of a file. The encoding of the file name is supposed to be UTF-8. Returns an empty string on failure. Can be called synchronously.

      Returns Text

      Throws:
      IOException
  • Method Details