public virtual void WriteObject(Asn1Object obj)
 {
     if (obj == null)
     {
         WriteNull();
     }
     else
     {
         obj.Encode(this);
     }
 }