GetInstance() 공개 정적인 메소드

public static GetInstance ( Asn1TaggedObject obj, bool explicitly ) : DerVisibleString
obj Asn1TaggedObject
explicitly bool
리턴 DerVisibleString
예제 #1
0
 public static DerVisibleString GetInstance(object obj)
 {
     if (obj == null || obj is DerVisibleString)
     {
         return((DerVisibleString)obj);
     }
     if (obj is Asn1OctetString)
     {
         return(new DerVisibleString(((Asn1OctetString)obj).GetOctets()));
     }
     if (obj is Asn1TaggedObject)
     {
         return(DerVisibleString.GetInstance(((Asn1TaggedObject)obj).GetObject()));
     }
     throw new ArgumentException("illegal object in GetInstance: " + obj.GetType().Name);
 }
예제 #2
0
 public static DerVisibleString GetInstance(Asn1TaggedObject obj, bool explicitly)
 {
     return(DerVisibleString.GetInstance(obj.GetObject()));
 }