Java 类org.bouncycastle.asn1.dvcs.DVCSTime 实例源码

项目:ipack    文件:DVCSRequestInfo.java   
/**
 * Get request generation time if it is set.
 *
 * @return time of request, or null if it is not set.
 * @throws DVCSParsingException if a request time is present but cannot be extracted.
 */
public Date getRequestTime()
    throws DVCSParsingException
{
    DVCSTime time = data.getRequestTime();

    if (time == null)
    {
        return null;
    }

    try
    {
        if (time.getGenTime() != null)
        {
            return time.getGenTime().getDate();
        }
        else
        {
            TimeStampToken token = new TimeStampToken(time.getTimeStampToken());

            return token.getTimeStampInfo().getGenTime();
        }
    }
    catch (Exception e)
    {
        throw new DVCSParsingException("unable to extract time: " + e.getMessage(), e);
    }
}
项目:gwt-crypto    文件:DVCSRequestInfo.java   
/**
 * Get request generation time if it is set.
 *
 * @return time of request, or null if it is not set.
 * @throws DVCSParsingException if a request time is present but cannot be extracted.
 */
public Date getRequestTime()
    throws DVCSParsingException
{
    DVCSTime time = data.getRequestTime();

    if (time == null)
    {
        return null;
    }

    try
    {
        if (time.getGenTime() != null)
        {
            return time.getGenTime().getDate();
        }
        else
        {
            TimeStampToken token = new TimeStampToken(time.getTimeStampToken());

            return token.getTimeStampInfo().getGenTime();
        }
    }
    catch (Exception e)
    {
        throw new DVCSParsingException("unable to extract time: " + e.getMessage(), e);
    }
}
项目:Aki-SSL    文件:DVCSRequestInfo.java   
/**
 * Get request generation time if it is set.
 *
 * @return time of request, or null if it is not set.
 * @throws DVCSParsingException if a request time is present but cannot be extracted.
 */
public Date getRequestTime()
    throws DVCSParsingException
{
    DVCSTime time = data.getRequestTime();

    if (time == null)
    {
        return null;
    }

    try
    {
        if (time.getGenTime() != null)
        {
            return time.getGenTime().getDate();
        }
        else
        {
            TimeStampToken token = new TimeStampToken(time.getTimeStampToken());

            return token.getTimeStampInfo().getGenTime();
        }
    }
    catch (Exception e)
    {
        throw new DVCSParsingException("unable to extract time: " + e.getMessage(), e);
    }
}
项目:irma_future_id    文件:DVCSRequestInfo.java   
/**
 * Get request generation time if it is set.
 *
 * @return time of request, or null if it is not set.
 * @throws DVCSParsingException if a request time is present but cannot be extracted.
 */
public Date getRequestTime()
    throws DVCSParsingException
{
    DVCSTime time = data.getRequestTime();

    if (time == null)
    {
        return null;
    }

    try
    {
        if (time.getGenTime() != null)
        {
            return time.getGenTime().getDate();
        }
        else
        {
            TimeStampToken token = new TimeStampToken(time.getTimeStampToken());

            return token.getTimeStampInfo().getGenTime();
        }
    }
    catch (Exception e)
    {
        throw new DVCSParsingException("unable to extract time: " + e.getMessage(), e);
    }
}
项目:irma_future_id    文件:DVCSParseTest.java   
private void validate(String name, DVCSTime result, DVCSTime expected)
{
    if (areNull(name, result, expected))
    {
        return;
    }
    validate(name + ".genTime", result.getGenTime(), expected.getGenTime());
    validate(name + ".timeStampToken", result.getTimeStampToken(), expected.getTimeStampToken());
}
项目:bc-java    文件:DVCSRequestInfo.java   
/**
 * Get request generation time if it is set.
 *
 * @return time of request, or null if it is not set.
 * @throws DVCSParsingException if a request time is present but cannot be extracted.
 */
public Date getRequestTime()
    throws DVCSParsingException
{
    DVCSTime time = data.getRequestTime();

    if (time == null)
    {
        return null;
    }

    try
    {
        if (time.getGenTime() != null)
        {
            return time.getGenTime().getDate();
        }
        else
        {
            TimeStampToken token = new TimeStampToken(time.getTimeStampToken());

            return token.getTimeStampInfo().getGenTime();
        }
    }
    catch (Exception e)
    {
        throw new DVCSParsingException("unable to extract time: " + e.getMessage(), e);
    }
}
项目:bc-java    文件:DVCSParseTest.java   
private void validate(String name, DVCSTime result, DVCSTime expected)
{
    if (areNull(name, result, expected))
    {
        return;
    }
    validate(name + ".genTime", result.getGenTime(), expected.getGenTime());
    validate(name + ".timeStampToken", result.getTimeStampToken(), expected.getTimeStampToken());
}
项目:ipack    文件:VPKCRequestBuilder.java   
public void setRequestTime(Date requestTime)
{
    requestInformationBuilder.setRequestTime(new DVCSTime(requestTime));
}
项目:ipack    文件:VSDRequestBuilder.java   
public void setRequestTime(Date requestTime)
{
    requestInformationBuilder.setRequestTime(new DVCSTime(requestTime));
}
项目:gwt-crypto    文件:VPKCRequestBuilder.java   
public void setRequestTime(Date requestTime)
{
    requestInformationBuilder.setRequestTime(new DVCSTime(requestTime));
}
项目:gwt-crypto    文件:VSDRequestBuilder.java   
public void setRequestTime(Date requestTime)
{
    requestInformationBuilder.setRequestTime(new DVCSTime(requestTime));
}
项目:Aki-SSL    文件:VPKCRequestBuilder.java   
public void setRequestTime(Date requestTime)
{
    requestInformationBuilder.setRequestTime(new DVCSTime(requestTime));
}
项目:Aki-SSL    文件:VSDRequestBuilder.java   
public void setRequestTime(Date requestTime)
{
    requestInformationBuilder.setRequestTime(new DVCSTime(requestTime));
}
项目:irma_future_id    文件:VPKCRequestBuilder.java   
public void setRequestTime(Date requestTime)
{
    requestInformationBuilder.setRequestTime(new DVCSTime(requestTime));
}
项目:irma_future_id    文件:VSDRequestBuilder.java   
public void setRequestTime(Date requestTime)
{
    requestInformationBuilder.setRequestTime(new DVCSTime(requestTime));
}
项目:bc-java    文件:VPKCRequestBuilder.java   
public void setRequestTime(Date requestTime)
{
    requestInformationBuilder.setRequestTime(new DVCSTime(requestTime));
}
项目:bc-java    文件:VSDRequestBuilder.java   
public void setRequestTime(Date requestTime)
{
    requestInformationBuilder.setRequestTime(new DVCSTime(requestTime));
}