utils namespace

Functions

  • IsDefinedAndNotNull
  • areCompatibleDataTypes - Returns `true` if two data types passed in parameters are compatible - so it's safe to copy the values between two expressions with these two types
  • assign - Copy the content of all objests passed in `args` parameters into `target` and returns the result NB: This function copies only the first level properties. For a deep copy please use `assignDeep`
  • assignDeep - Copy the content of all objests passed in `args` parameters into `target` and returns the result NB: This function make a deep copy - so `assignDeep` will be called recursively for all object properties on the first level.
  • copyArrayTo
  • createArrayFrom
  • dateTimeToStr - Returns string representation of the date/time value according to the custom format (second parameter) The format is compatible with the one used in .NET: https://docs.microsoft.com/en-us/dotnet/standard/base-types/custom-date-and-time-format-strings
  • fillArray
  • findItemById - Searches an array of the objects which implement ItemWithId by ID Returs the found object or null.
  • findItemIndexById