public static GetInstance ( object obj ) : |
||
obj | object | |
Résultat |
public static Challenge GetInstance(object obj)
{
if (obj is Challenge)
return (Challenge)obj;
if (obj is Asn1Sequence)
return new Challenge((Asn1Sequence)obj);
throw new ArgumentException("Invalid object: " + obj.GetType().Name, "obj");
}
public virtual Challenge[] ToChallengeArray() { Challenge[] array = new Challenge[content.Count]; for (int i = 0; i != array.Length; i++) { array[i] = Challenge.GetInstance(content[i]); } return(array); }