public class

HashChangedHandler

extends Object
java.lang.Object
   ↳ com.atlassian.applinks.core.util.HashChangedHandler

Class Overview

This class manages the last modified date of a single HTTP resource.

Summary

Public Constructors
HashChangedHandler(int hashCode)
Public Methods
boolean checkRequest(HttpServletRequest request, HttpServletResponse response)
Check whether we need to generate a response for this request.
static boolean checkRequest(HttpServletRequest request, HttpServletResponse response, int hashCode)
This static method is used when the resource being served by the servlet keeps track of the object hashcode, and so no state needs to be maintained by this handler.
[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public HashChangedHandler (int hashCode)

Public Methods

public boolean checkRequest (HttpServletRequest request, HttpServletResponse response)

Check whether we need to generate a response for this request. Set the necessary headers on the response, and if we don't need to provide content, set the response status to 304. If this method returns true, the caller should not perform any more processing on the request.

Returns
  • true if we don't need to provide any data to satisfy this request

public static boolean checkRequest (HttpServletRequest request, HttpServletResponse response, int hashCode)

This static method is used when the resource being served by the servlet keeps track of the object hashcode, and so no state needs to be maintained by this handler.