LocalizedExternalFile (install4j API)
Description: declaration: package: com.install4j.api.beans, class: LocalizedExternalFile

# Class LocalizedExternalFile

java.lang.Object
com.install4j.api.beans.LocalizedExternalFile

All Implemented Interfaces:
  `Serializable`

public class LocalizedExternalFile extends Object implements Serializable
Container for a set of localized files that represent a single `ExternalFile` with textual content. If you want the user to be able to specify localized versions of a text file for a single property, you can declare the property to be of type `LocalizedExternalFile`. Important: you have to initialize the field with an instance rather than leaving it `null`.

In the install4j IDE, the user will be presented with a dialog that allows file selection for all installer languages that are configured on the General Settings->Languages tab. At runtime, call `Context.getExternalFile(LocalizedExternalFile, boolean)` to get the actual file for further use in your bean implementation.

In your bean info, use the `FilePropertyDescriptor` class to register the property. All attributes of `FilePropertyDescriptor` are supported for `LocalizedExternalFile`.

See Also:
  - `ExternalFile`
  - Serialized Form

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `LocalizedExternalFile()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `boolean`
  `equals(Object o)`
  `Map<String, ExternalFile>`
  `getLanguageIdToExternalFile()`
  Returns the map from language IDs to `ExternalFile`s.
  `int`
  `hashCode()`
  `void`
  `setLanguageIdToExternalFile(Map<String, ExternalFile> languageIdToExternalFile)`
  Sets the map from language IDs to `ExternalFile`s.

  ### Methods inherited from class Object

  `clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### LocalizedExternalFile

    public LocalizedExternalFile()

- ## Method Details

  - ### getLanguageIdToExternalFile

    public Map<String, ExternalFile> getLanguageIdToExternalFile()
    Returns the map from language IDs to `ExternalFile`s. You do not have to use this method, a more convenient way to retrieve the actual file at runtime is to call `Context.getExternalFile(LocalizedExternalFile, boolean)`.
    Returns:
      the map

  - ### setLanguageIdToExternalFile

    public void setLanguageIdToExternalFile(Map<String, ExternalFile> languageIdToExternalFile)
    Sets the map from language IDs to `ExternalFile`s. This method is called by the install4j IDE.
    Parameters:
      `languageIdToExternalFile` - the map

  - ### equals

    public boolean equals(Object o)
    Overrides:
      `equals` in class `Object`

  - ### hashCode

    public int hashCode()
    Overrides:
      `hashCode` in class `Object`