Inheritance: AMFReader
Ejemplo n.º 1
0
 public DataAMF3Message(RTMPMessage x)
     : base(x)
 {
     using (var reader=new AMF3Reader(new MemoryStream(x.Body))) {
     this.propertyName = (string)reader.ReadValue();
     var arguments = new List<AMFValue>();
     while (reader.BaseStream.Position<reader.BaseStream.Length) {
       arguments.Add(reader.ReadValue());
     }
     this.arguments = arguments;
       }
 }
Ejemplo n.º 2
0
 public CommandAMF3Message(RTMPMessage x)
     : base(x)
 {
     using (var reader=new AMF3Reader(new MemoryStream(x.Body))) {
     this.commandName   = (string)reader.ReadValue();
     this.transactionId = (int)reader.ReadValue();
     this.commandObject = reader.ReadValue();
     if (AMFValue.IsNull(CommandObject)) {
       this.commandObject = null;
     }
     var args = new List<AMFValue>();
     while (reader.BaseStream.Position<reader.BaseStream.Length) {
       args.Add(reader.ReadValue());
     }
     this.arguments = args;
       }
 }