public static String toString(PolicyQualifierInfo policyQualifierInfo) throws IOException {
  StringBuffer sbPolicyQualifier=new StringBuffer();
  ASN1ObjectIdentifier policyQualifierId=policyQualifierInfo.getPolicyQualifierId();
  CertificatePolicyQualifierType certificatePolicyQualifierType=CertificatePolicyQualifierType.resolveOid(policyQualifierId.getId());
  if (certificatePolicyQualifierType == PKIX_CPS_POINTER_QUALIFIER) {
    DERIA5String cpsPointer=((DERIA5String)policyQualifierInfo.getQualifier());
    sbPolicyQualifier.append(MessageFormat.format(res.getString("PolicyInformationUtil.CpsPointer"),cpsPointer));
  }
 else   if (certificatePolicyQualifierType == PKIX_USER_NOTICE_QUALIFIER) {
    ASN1Encodable userNoticeObj=policyQualifierInfo.getQualifier();
    UserNotice userNotice=UserNotice.getInstance(userNoticeObj);
    sbPolicyQualifier.append(MessageFormat.format(res.getString("PolicyInformationUtil.UserNotice"),toString(userNotice)));
  }
  return sbPolicyQualifier.toString();
}

public static String toString ( PolicyQualifierInfo policyQualifierInfo ) throws IOException { StringBuffer sbPolicyQualifier = new StringBuffer ( ) ; ASN1ObjectIdentifier policyQualifierId = policyQualifierInfo . getPolicyQualifierId ( ) ; CertificatePolicyQualifierType certificatePolicyQualifierType = CertificatePolicyQualifierType . resolveOid ( policyQualifierId . getId ( ) ) ; if ( certificatePolicyQualifierType == PKIX_CPS_POINTER_QUALIFIER ) { DERIA5String cpsPointer = ( ( DERIA5String ) policyQualifierInfo . getQualifier ( ) ) ; sbPolicyQualifier . append ( MessageFormat . format ( res . getString ( "PolicyInformationUtil.CpsPointer" ) , cpsPointer ) ) ; } else if ( certificatePolicyQualifierType == PKIX_USER_NOTICE_QUALIFIER ) { ASN1Encodable userNoticeObj = policyQualifierInfo . getQualifier ( ) ; UserNotice userNotice = UserNotice . getInstance ( userNoticeObj ) ; sbPolicyQualifier . append ( MessageFormat . format ( res . getString ( "PolicyInformationUtil.UserNotice" ) , toString ( userNotice ) ) ) ; } return sbPolicyQualifier . toString ( ) ; }
get string representation of policy qualifier info .
