question: private ContextHandler createContextHandler ( String directory , boolean isInJar , File installRootDirectory , int expiresInSeconds ) { final ContextHandler contextHandler = new ContextHandler ( ) ; final ResourceHandler resourceHandler = new ExpiresResourceHandler ( expiresInSeconds ) ; final String directoryWithSlash = "/" + directory ; contextHandler . setContextPath ( directoryWithSlash ) ; Resource directoryResource = getDirectoryResource ( directory , isInJar , installRootDirectory ) ; directoryResource = new JsMinifyingResource ( directoryResource ) ; if ( isInJar ) { directoryResource = new CachingResource ( directoryResource , directoryWithSlash ) ; } resourceHandler . setBaseResource ( directoryResource ) ; if ( ! isInJar ) { resourceHandler . setMinMemoryMappedContentLength ( 0 ) ; } contextHandler . setHandler ( resourceHandler ) ; return contextHandler ; }
target:  Creates a context handler for the directory. 