Defining Custom UploadTags - DAM v4.7.0

1 Process overview

  1. ProcessUpload or ProcessReIdentify WebService methods identify the Upload as usual.
  2. All defined UploadTags are parsed against the asset_information.infoxml document
  3. A batchUpdate call is prepared from AssetType, Upload ItemID and UploadTag/value Dictionary
  4. BatchUpdate WebService is called.

2 UploadTagĀ definition

Uploadtagname_defintion table

Column

DataType

Description

uploadtagname_definitionid

int

Primary key

uploadtagname

string

uploadTagname

xpath

string

Xpath used to extract the tag value

xmlnamespaces

string

Xmlnamespaces needed by Xpath. Space seperated list of xml namespace definitions: xmlns:rdf="rdf namespace url" xmlns:iptc="iptc namespace url"

functionname

string

(Optional) function name

functionrequireduploadtagnames

string

Tags that should have already been parsed before this tag is processed

enabled

bit

Is this uploadTag enabled

systemDefined

bit

Is this uploadTag defined by Digizuite

3 Defining custom uploadtags

Important: Custom tags that clash with future updates of DAM Center will be renamed to <tagname>RENAMED<GUID>.

To avoid this, always start custom tags with custom: and set systemDefined to 0.

4 Defined functions DigiZuiteLogic\UploadInformation\Bll\TagFunctions.bll.cs

If requiredTags contains uploadtags, the first tag is used as the argument source for the function, otherwise the Xpath is used as the argument source.

  • ShortestString -Ā Selects shortest string
  • LongestString -Ā Selects longest string
  • SelectInt -Ā Selects values which contain only numbers that match the regular expression:
"^\s*\d+\s*$"
  • SelectNonInt -Ā Selects values that do not match SelectInt
"^\s*\d+\s*$"
  • SelectIntFromStart -Ā Selects values which begin with numbers that match the regular expression:

"^\s*\d+.*$"
  • Only the number part is returned.
  • Example: 1234kb would be returned as 1234
  • SelectDecimal -Ā Selects values which can be parsed as decimal
  • SelectAspect -Ā Selects all values that match the regular expression:
"^\s*\d+[\:/]\d+\s*$"
  • Example: 16/9 or 4:3
  • SelectDuration -Ā Selects all values that match the regular expression:
@"(?n:^(?=\d)(?<time>(?<hours>[01]\d|2[0-3]):(?<minutes>[0-5]\d):(?<seconds>[0-5]\d)\.(?<milliseconds>\d{3}))$)"
  • Example: 23:59:59.120
  • SelectChannelPositions -Ā Selects all values that match the regular expression:
@"^\s*\d+(?:\.\d+)?/\d+(?:\.\d+)?/\d+(?:\.\d+)?\s*$"
  • Example: 2/0/0 or 5/2/1.1
  • ValueCount -Ā Returns count of values
  • JoinBySemicolon -Ā Returns values joined by semicolons as a single string
  • JoinBySpace -Ā Returns values joined by spaces as a single string
  • JoinByComma -Ā Returns values joined by commas as a single string
  • JoinByForwardSlash -Ā Returns values joined by forward slashes as a single string
  • JoinByBackSlash -Ā Returns values joined by back slashes as a single string
  • JoinByCrLf -Ā Returns values joined by forward carrier linefeeds as a single string
  • JoinByVerticalbar - Returns values joined by vertical bar | as a single string
  • SplitBySemicolon - Returns a list of values Split by semicolon
  • SplitBySpaceĀ - Returns a list of values Split by space
  • SplitByComma - Returns a list of values Split by Comma
  • SplitByCrLf -Ā Returns a list of values Split by carrier linefeeds
  • SplitByForwardSlashĀ -Ā Returns a list of values Split by Forward slash
  • SplitByBackSlashĀ -Ā Returns a list of values Split by Back slash
  • SplitByVerticalbarĀ Ā -Ā Returns a list of values Split by Vertical Bar |
  • WidthFromGeometry -Ā Return the width from the Imagemagick geometry value
  • HeightFromGeometry -Ā Returns the height from the Imagemagick geometry value
  • XOffsetFromGeometry -Ā Returns the X-Offset from the Imagemagick geometry value
  • YOffsetFromGeometry -Ā Returns the Y-Offset from the Imagemagick geometry value
  • DpiXFromResolution -Ā Returns the x part of the resolution (96x96)
  • DpiYFromResolution -Ā Returns the y part of the resolution (96x96)
  • RoundVideoRotation -Ā Returns the rotation rounded to nearest 90Ā°

Table of Contents