net.shibboleth.utilities.java.support.annotation.Duration类的使用及代码示例

x33g5p2x  于2022-01-18 转载在 其他  
字(6.2k)|赞(0)|评价(0)|浏览(153)

本文整理了Java中net.shibboleth.utilities.java.support.annotation.Duration类的一些代码示例,展示了Duration类的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Duration类的具体详情如下:
包路径:net.shibboleth.utilities.java.support.annotation.Duration
类名称:Duration

Duration介绍

暂无

代码示例

代码示例来源:origin: org.opensaml/opensaml-saml-impl

/**
 * Set the maximum interval, in milliseconds, between now and the <code>validUntil</code> date.
 * A value of less than 1 indicates that there is no restriction.
 * 
 * @param validity time in milliseconds between now and the <code>validUntil</code> date
 */
@Duration public void setMaxValidityInterval(@Duration final long validity) {
  maxValidityInterval = validity;
}

代码示例来源:origin: net.shibboleth.idp/idp-attribute-resolver-spring

/**
 * Converts the supplied duration to milliseconds and divides it by the divisor. Useful for modifying durations
 * while resolving property replacement.
 * 
 * @param duration the duration (which may have gone through spring translation from iso to long)
 * @param divisor to modify the duration with
 * 
 * @return result of the division
 */
@Duration public static long buildDuration(@Duration final long duration, final long divisor) {
  return duration / divisor;
}

代码示例来源:origin: net.shibboleth.idp/idp-attribute-resolver-api

/**
 * Set how long to wait until we declare the connector (potentially) alive again.
 *
 * @param delay what to set
 */
@Duration public void setNoRetryDelay(@Duration final long delay) {
  noRetryDelay = delay;
}

代码示例来源:origin: org.opensaml/opensaml-saml-impl

/**
 * Gets the maximum amount of time, in milliseconds, between refresh intervals.
 * 
 * @return maximum amount of time between refresh intervals
 */
@Duration public long getMaxRefreshDelay() {
  return maxRefreshDelay;
}

代码示例来源:origin: org.opensaml/opensaml-saml-impl

/**
 * Gets the minimum amount of time, in milliseconds, between refreshes.
 * 
 * @return minimum amount of time, in milliseconds, between refreshes
 */
@Duration public long getMinRefreshDelay() {
  return minRefreshDelay;
}

代码示例来源:origin: org.opensaml/opensaml-saml-impl

/**
 * Get the maximum interval, in milliseconds, between now and the <code>validUntil</code> date.
 * A value of less than 1 indicates that there is no restriction.
 * 
 * @return maximum interval, in milliseconds, between now and the <code>validUntil</code> date
 */
@Duration public long getMaxValidityInterval() {
  return maxValidityInterval;
}

代码示例来源:origin: net.shibboleth.idp/idp-attribute-resolver-spring

/**
 * Data Connector property "noRetryDelay".
 * 
 * @param delay the value to set
 */
@Duration public void setNoRetryDelay(@Nullable @Duration final Long delay) {
  noRetryDelay = delay;
}

代码示例来源:origin: net.shibboleth.idp/idp-attribute-resolver-spring

/**
 * Data Connector property "noRetryDelay".
 * 
 * @return the value of property to set or null if never set
 */
@Nullable @Duration public Long getNoRetryDelay() {
  return noRetryDelay;
}

代码示例来源:origin: net.shibboleth.idp/idp-profile-api

/**
 * Set the system time offset, which affects the reference date for comparisons.
 * By default all comparisons are against system time, i.e. zero offset.
 *
 * @param offset System time offset. A negative value decreases the target date (sooner);
 *                         a positive value increases the target date (later).
 */
@Duration public void setOffset(@Duration final long offset) {
  systemTimeOffset = org.joda.time.Duration.millis(offset);
}

代码示例来源:origin: org.opensaml/opensaml-saml-impl

/**
 * Set the artifact entry lifetime in milliseconds.
 * 
 * @param lifetime artifact entry lifetime in milliseconds
 */
@Duration public void setArtifactLifetime(@Duration @Positive final long lifetime) {
  artifactLifetime = Constraint.isGreaterThan(0, lifetime, "Artifact lifetime must be greater than zero");
}

代码示例来源:origin: net.shibboleth.idp/idp-profile-api

/** {@inheritDoc} */
  @Override
  @Nullable @Positive @Duration public Long getStorageExpiration() {
    return storageExpiration;
  }
}

代码示例来源:origin: net.shibboleth.idp/idp-session-api

/**
 * Set the last activity instant, in milliseconds since the epoch, for the session.
 * 
 * @param instant last activity instant, in milliseconds since the epoch, for the session, must be greater than 0
 * @throws SessionException if an error occurs updating the session
 */
@Duration public void setLastActivityInstant(@Duration @Positive final long instant) throws SessionException {
  doSetLastActivityInstant(instant);
}

代码示例来源:origin: org.opensaml/opensaml-saml-impl

/**
 * Get the clock skew.
 * 
 * @return the clock skew
 */
@NonNegative @Duration public long getClockSkew() {
  return clockSkew;
}

代码示例来源:origin: org.opensaml/opensaml-saml-impl

/**
 * Set the artifact entry lifetime in milliseconds.
 * 
 * @param lifetime artifact entry lifetime in milliseconds
 */
@Duration public void setArtifactLifetime(@Duration @Positive final long lifetime) {
  artifactLifetime = Constraint.isGreaterThan(0, lifetime, "Artifact lifetime must be greater than zero");
}

代码示例来源:origin: net.shibboleth.idp/idp-saml-impl

/**
 * Get the SQL query timeout.
 * 
 * @return the timeout in milliseconds
 */
@NonNegative @Duration public long getQueryTimeout() {
  return queryTimeout;
}

代码示例来源:origin: net.shibboleth.idp/idp-session-api

/**
 * Set the last activity instant, in milliseconds since the epoch, for the session.
 * 
 * <p>This manipulates only the internal state of the object. The {@link #setLastActivityInstant(long)}
 * method must be overridden to support other persistence requirements.</p>
 * 
 * @param instant last activity instant, in milliseconds since the epoch, for the session, must be greater than 0
 */
@Duration public void doSetLastActivityInstant(@Duration @Positive final long instant) {
  lastActivityInstant = Constraint.isGreaterThan(0, instant, "Last activity instant must be greater than 0");
}

代码示例来源:origin: net.shibboleth.idp/idp-session-impl

/**
 * Get the session inactivity timeout policy in milliseconds.
 * 
 * @return inactivity timeout
 */
@Duration @Positive public long getSessionTimeout() {
  return sessionTimeout;
}

代码示例来源:origin: org.opensaml/opensaml-storage-api

/**
 * Gets the number of milliseconds between one cleanup and another. A value of 0 indicates that no cleanup will be
 * performed.
 * 
 * @return number of milliseconds between one cleanup and another
 */
@NonNegative @Duration public long getCleanupInterval() {
  return cleanupInterval;
}

代码示例来源:origin: net.shibboleth.idp/idp-cas-impl

/**
 * Sets the ticket validity period.
 * 
 * @param millis Ticket validity period in milliseconds.
 */
@Duration public void setTicketValidityPeriod(@Duration @Positive final long millis) {
  ticketValidityPeriod = Constraint.isGreaterThan(0, millis, "Ticket validity period must be positive.");
}

代码示例来源:origin: org.opensaml/opensaml-saml-impl

/**
 * Get the artifact entry lifetime in milliseconds.
 * 
 * @return the artifact entry lifetime in milliseconds
 */
@Duration @Positive public long getArtifactLifetime() {
  return artifactLifetime;
}

相关文章

Duration类方法