Posts

Showing posts from January 19, 2019

Treasure map

Image
For the 2007 album by Nan Quan Mama, see Treasure Map. Map created by Robert Louis Stevenson in Treasure Island A treasure map is a map that marks the location of buried treasure, a lost mine, a valuable secret or a hidden locale. More common in fiction than in reality, "pirate treasure maps" are often depicted in works of fiction as hand drawn and containing arcane clues for the characters to follow. Regardless of the term's literary use, anything that meets the broad definition of a "map" that describes the location of a "treasure" could appropriately be called a "treasure map." Contents 1 Treasure maps in history 1.1 Copper scroll 1.2 Pirates 1.3 El Dorado 2 Treasure maps in fiction 2.1 Literature 2.2 Film 3 See also 4 References 5 External links Treasure maps in history Copper scroll One of the earliest known instances of a document listing buried treasure is the coppe

How to check if requested URL is a servlet (in a filter)?

Image
0 I have a filter that maps onto all requests: @WebFilter({ "/*" }) I use this filter to do url mapping so that i can have vanity urls for my jsps and to handle 404s, however it also means i have to manually add the servlets to process the request chain normally: String requri = ((HttpServletRequest) request).getRequestURI(); //get requested url String page = ""; if(requri.equals("/contact/") || requri.equals("/contact")) page = "contact.jsp"; else if(requri.equals("/about/") || requri.equals("/about")) page = "about.jsp"; else if(requri.equals("/SomeServlet")) chain.doFilter(request, response); //if requested url is a servlet, then carry on normally //send requested url to servlet which will then f