Examples of ValidityIntervalType


Examples of org.w3._2002._03.xkms_.ValidityIntervalType

    
     return retval;
   }
  
  protected ValidityIntervalType getValidityInterval(X509Certificate cert) {
      ValidityIntervalType valitityIntervalType = xkmsFactory.createValidityIntervalType();
    try {     
      GregorianCalendar notBeforeGregorianCalendar = new GregorianCalendar();
      notBeforeGregorianCalendar.setTime(cert.getNotBefore());
        XMLGregorianCalendar notBeforeXMLGregorianCalendar = javax.xml.datatype.DatatypeFactory.newInstance().newXMLGregorianCalendar(notBeforeGregorianCalendar);
        notBeforeXMLGregorianCalendar.normalize();
        valitityIntervalType.setNotBefore(notBeforeXMLGregorianCalendar);
     
      GregorianCalendar notAfterGregorianCalendar = new GregorianCalendar();
      notAfterGregorianCalendar.setTime(cert.getNotAfter());
        XMLGregorianCalendar notAfterXMLGregorianCalendar = javax.xml.datatype.DatatypeFactory.newInstance().newXMLGregorianCalendar(notAfterGregorianCalendar);
        notAfterXMLGregorianCalendar.normalize();
        valitityIntervalType.setNotOnOrAfter(notAfterXMLGregorianCalendar);     
     
    } catch (DatatypeConfigurationException e) {
      log.error(intres.getLocalizedMessage("xkms.errorsetvalidityinterval"),e);     
    }   
     
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.