question: public static boolean clearIfNotModified ( HttpServletRequest request , HttpServletResponse response , Collection < ? extends IdentifiableObject > objects ) { String tag = QUOTE + IdentifiableObjectUtils . getLastUpdatedTag ( objects ) + QUOTE ; response . setHeader ( HEADER_ETAG , tag ) ; String inputTag = request . getHeader ( HEADER_IF_NONE_MATCH ) ; if ( objects != null && inputTag != null && inputTag . equals ( tag ) ) { response . setStatus ( HttpServletResponse . SC_NOT_MODIFIED ) ; objects . clear ( ) ; return true ; } return false ; }
target:  Clears the given collection if it is not modified according to the HTTP cache validation. This method looks up the ETag sent in the request from the "If-None-Match" header value, generates an ETag based on the given collection of IdentifiableObjects and compares them for equality. If this evaluates to true, it will set status code 304 Not Modified on the response and remove all elements from the given list. It will set the ETag header on the response in any case.