Description
The SFormatToFacets component allows you to transform a SFormat into Facets.
Implementation
example: Here, the value in the "myFacet" slot has been retrieved thanks to the SFormat in the Input slot and converted into Facets in the Output slot
(the "myFacet" slot is a dynamic slot added for the example, it won't be present by default in the component)
Properties
Examples:
For any Boolean facet (showDate, showMilliseconds, multiLine, etc), your string should look like this: <key>=b:<boolean value>, for example showDate=b:false
For any Integer facet (precision, fieldWidth, etc), your string should look like this: <key>=i:<integer value>, for example fieldWidth=i:10
For any Float facet (min, max, etc), your string should look like this: <key>=f:<float value>, for example max=f:10.0
For any String facet (trueText, falseTexte, etc), your string should look like this: <key>=s:<escaped string value>, for example trueText=s:on
For the maxOverrideDuration facet, your string should look like this: maxOverrideDuration=r:<time in milliseconds>, for example maxOverrideDuration=r:3600000
For the range facet,
For the Unit facet, it is rather complicated, your string should look like this:
units=u:<unitName>;<symbol>;<dimension>;*<scale>;+<offset>; for example: units=u:square meter;m²;(m2);;
some rules:
the unitNames, symbols etc are available in the units.xml file in your C:\Niagara\Niagara-xxx\defaults folder
There are also keys of the TimeZone type but they are far too complicated to be done by hand.
Finally if you want to use more than one key, you can separate your key value pairs with the pipe "|" character. For example: min=f:0.0|max=f:10.0