public override void DeserializeToken (JSONReader JSONReader, string Tag) {
switch (Tag) {
case "protected" : {
Protected = JSONReader.ReadBinary ();
break;
}
case "unprotected" : {
Unprotected = JSONReader.ReadBinary ();
break;
}
case "iv" : {
IV = JSONReader.ReadBinary ();
break;
}
case "ciphertext" : {
CipherText = JSONReader.ReadBinary ();
break;
}
case "tag" : {
JTag = JSONReader.ReadBinary ();
break;
}
case "aad" : {
AdditionalAuthenticatedData = JSONReader.ReadBinary ();
break;
}
case "recipients" : {
// Have a sequence of values
bool _Going = JSONReader.StartArray ();
Recipients = new List <Recipient> ();
while (_Going) {
// an untagged structure.
var _Item = new Recipient (JSONReader);
Recipients.Add (_Item);
_Going = JSONReader.NextArray ();
}
break;
}
default : {
break;
}
}
// check up that all the required elements are present
}