Page tree
Skip to end of metadata
Go to start of metadata



ExtractLanguageFiles (application, directory path, allowOverwrite)


Supported in iOS Supported in Android

Description

Extract the language files from an application to a specified path during runtime.

Note: Throws an exception if the name or the path is invalid.

Parameters

  • Application: The application identifier as shown in the applications manager.
  • Directory Path: The destination directory where to extract the language files.
  • allowOverwrite:

    o  When set to true, the extracted files of the application will overwrite any pre-existing files in the destination directory.

    o  When set to false and some of the extracted files are colliding with the pre-existing files, an exception will be thrown.

Note:    You can get the mapping between the language names and their corresponding paths by using the getLastCommandResultMap The key to use is “LanguageFiles”.  See example below

Usage

Example Script: ExtractLanguageFiles

Scenario: In the following example I will extract the language files from the IMDb application through SeeTestAutomation and via code. The extracted files also displayed at the Log tab.

The extracted files also shown at the report’s “Debug Properties” tab.

It is possible also to extract language files via code and to receive the mapping between the language names and the file paths using the key “LanguageFiles”, and theSeeTestAutomation- GetLastCommandResultMap.

Code Examples

Java Example
client.extractLanguageFiles("com.imdb.mobile/.Home", "c:\\imdb", true);
client.getLastCommandResultMap().get("LanguageFiles");
C# Example
client.ExtractLanguageFiles("com.imdb.mobile/.Home", "c:\\imdb", true);
client.GetLastCommandResultMap().get("LanguageFiles");
  • No labels