Home
last modified time | relevance | path

Searched refs:fileOrdirectory (Results 1 – 2 of 2) sorted by relevance

/external/nanohttpd/nanolets/src/main/java/fi/iki/elonen/router/
DRouterNanoHTTPD.java219 File fileOrdirectory = uriResource.initParameter(File.class); in get() local
221 fileOrdirectory = new File(fileOrdirectory, pathPart); in get()
223 if (fileOrdirectory.isDirectory()) { in get()
224 fileOrdirectory = new File(fileOrdirectory, "index.html"); in get()
225 if (!fileOrdirectory.exists()) { in get()
226 fileOrdirectory = new File(fileOrdirectory.getParentFile(), "index.htm"); in get()
229 if (!fileOrdirectory.exists() || !fileOrdirectory.isFile()) { in get()
233 …unkedResponse(getStatus(), getMimeTypeForFile(fileOrdirectory.getName()), fileToInputStream(fileOr… in get()
240 protected BufferedInputStream fileToInputStream(File fileOrdirectory) throws IOException { in fileToInputStream() argument
241 return new BufferedInputStream(new FileInputStream(fileOrdirectory)); in fileToInputStream()
/external/nanohttpd/nanolets/src/test/java/fi/iki/elonen/router/
DAppNanolets.java126 protected BufferedInputStream fileToInputStream(File fileOrdirectory) throws IOException { in fileToInputStream() argument
127 if (fileOrdirectory.getName().equals("exception.html")) { in fileToInputStream()
130 return super.fileToInputStream(fileOrdirectory); in fileToInputStream()