Skip to main content
Open

Add String functions for equivalent functionality to TextDecoder/TextEncoder

Related products:Transformers
  • April 29, 2021
  • 1 reply
  • 10 views

cfvonner
Supporter

I'm working more and more with JSON data coming from an FME Server Automation webhook. Since the data isn't passing through a Reader in my workspace (it comes in via a published parameter), some JSON values may be encoded for URL (% codes for many special characters). After passing through a JSONFlattener, rather than having to chain together multiple TextDecode transformers to account for all the attributes that might be encoded, it would be simpler to be able to decode all the attributes inside an AttributeManager (or even an AttributeCreator).


Unfortunately, there are no string functions currently available in AttributeManager/AttributeCopier to encode/decode attributes.


It would be great to have encode/decode functions to provide this functionality!

1 reply

cfvonner
Supporter
Forum|alt.badge.img+19
  • Author
  • Supporter
  • May 6, 2021

It occurred to me after posting this that I could treat the entire JSON data value as a single string and decode it before JSONFlattener/JSONFragmenter. So at least I don't have to chain one or more of these together for individual attributes.


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings