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'}) {
  Transport.builder.element('GetStreamUri', nest: () {
    Transport.builder.namespace(Xmlns.tr2);
    Transport.builder.element('Protocol', nest: () {
      Transport.builder.namespace(Xmlns.tt);
      Transport.builder.text(protocol);
    });

    Transport.builder.element('ProfileToken', nest: () {
      Transport.builder.namespace(Xmlns.tt);
      Transport.builder.text(profileToken);
    });
  });

  return Transport.builder.buildFragment();
}