-
public class FilePathProvider
-
-
Method Summary
Modifier and Type Method Description static StringgetCompressedTextFileFromLongMessage(Context context, String sFileName, String sBody)Compresses a long message into a zip file containing a text file.This method takes a long message string and creates a zip file containing a text file with the message.The zip file is stored in a specific directory designated for long messages. static FilegetFileLocationForLongMessage(Context context)Gets the file location for storing long messages.This method retrieves the directory for storing temporary long messages. -
-
Method Detail
-
getCompressedTextFileFromLongMessage
static String getCompressedTextFileFromLongMessage(Context context, String sFileName, String sBody)
Compresses a long message into a zip file containing a text file.This method takes a long message string and creates a zip file containing a text file with the message.The zip file is stored in a specific directory designated for long messages.
- Parameters:
context- The application context.sFileName- The desired file name for the text file (and the base name for the zip file).sBody- The long message string to be compressed.
-
getFileLocationForLongMessage
static File getFileLocationForLongMessage(Context context)
Gets the file location for storing long messages.This method retrieves the directory for storing temporary long messages.It first gets the base files directory using getFilesDirectory.Then, it creates a subdirectory named "temp_mpm" within the base directory if it doesn't exist.
- Parameters:
context- The application context.
-
-
-
-