diff --git a/spring-web/src/main/java/org/springframework/http/HttpHeaders.java b/spring-web/src/main/java/org/springframework/http/HttpHeaders.java index c41d04d69e..7e538ffe92 100644 --- a/spring-web/src/main/java/org/springframework/http/HttpHeaders.java +++ b/spring-web/src/main/java/org/springframework/http/HttpHeaders.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2012 the original author or authors. + * Copyright 2002-2013 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -412,8 +412,19 @@ public class HttpHeaders implements MultiValueMap, Serializable * Returns the value of the {@code IfModifiedSince} header. *

The date is returned as the number of milliseconds since January 1, 1970 GMT. Returns -1 when the date is unknown. * @return the header value + * @deprecated use {@link #getIfModifiedSince()} */ + @Deprecated public long getIfNotModifiedSince() { + return getIfModifiedSince(); + } + + /** + * Returns the value of the {@code If-Modified-Since} header. + *

The date is returned as the number of milliseconds since January 1, 1970 GMT. Returns -1 when the date is unknown. + * @return the header value + */ + public long getIfModifiedSince() { return getFirstDate(IF_MODIFIED_SINCE); }