Function applyTranslated

  • Applies properties from the source object to the target object, translating the property names based on the translation map. The translation map should have an entry per property that you wish to rename when it is applied on the target object. The key should be the name of the property on the source object and the value should be the desired name on the target object. The value may also be set to null or false to prohibit that property from being applied. By default, this function will also apply all other properties on the source object that are not listed in the translation map, but you can override this by supplying false for the applyOthers parameter.

    Parameters

    • target: any

      The target object

    • source: any

      The source object

    • translationMap: any

      A map listing property name translations

    • Optional applyOthers: boolean

      Set to false to prohibit application of properties not explicitly mentioned in the translation map.

    • Optional applyFunctions: boolean

      Set to false to prohibit application of properties that are functions

    Returns void

Generated using TypeDoc