getStreamUri static method

XmlDocumentFragment getStreamUri(
  1. String profileToken, {
  2. String protocol = 'RTSP',
})

XML for the getStreamUri, requires a profileToken

Implementation

static XmlDocumentFragment getStreamUri(String profileToken,
    {String protocol = 'RTSP'}) {
  builder.element('GetStreamUri', nest: () {
    builder.namespace(Xmlns.tr2);

    protocol.buildXml(
      builder,
      tag: 'Protocol',
    );

    builder.element('Protocol', nest: () {
      builder.namespace(Xmlns.tt);
      builder.text(protocol);
    });

    ReferenceToken(profileToken).buildXml(builder);
  });

  return builder.buildFragment();
}