Discussion (3)1
Log in or sign up to continue

Hello,\

You may find documentation on how to work with streams here: 
https://docs.intersystems.com/iris20191/csp/docbook/DocBook.UI.Page.cls?KEY=GOBJ_propstream

in BPL you can add a "code" element where you can create and populate your stream with data,. or you can add a "call" element to call a classmethod where you implement the code.

For example: to create a stream and write some data into it :
(if you need to have this stream data vailable for other components of the BPL it is best to use a %context property for it)

set stream  = ##class(%Stream.GlobalCharacter).%New()
do stream.Write("some text")
do stream.Write(%request.anyproperty)
do stream.Write(%context.anyproperty)

in your request / response messages to pass to BO you will have to add a stream property :

Property MyProp As %Stream.GlobalCharacter;