19 package org.turro.help;
21 import java.io.IOException;
22 import java.nio.file.DirectoryStream;
23 import java.nio.file.Files;
24 import java.nio.file.Path;
25 import java.nio.file.Paths;
26 import java.util.logging.Level;
27 import java.util.logging.Logger;
28 import org.turro.string.Strings;
29 import org.turro.elephant.context.ElephantContext;
30 import org.turro.elephant.context.ElephantProperties;
31 import org.turro.elephant.web.ElContext;
32 import org.turro.elephant.web.ElContextMap;
40 public static String
helpLink(String current) {
42 if(ctx !=
null && ctx.
getFile().exists()) {
44 if(webPath.startsWith(
"/")) {
46 if(stream.iterator().hasNext()) {
49 }
catch (IOException ex) {
72 return help(current)!=
null;
77 private static final String HELP_CONTEXT =
"help-context";
static String getRealPath(String path)
static String logMsg(String msg)
static String getContextProperty(String context, String property)
static ElContext getContext(IConstructor constructor)
static ElContext help(ElContext current)
static String helpLink(String current)
static ElContext help(String path)
static String getHelpContextAttribute(String attribute, String defaultValue)
static boolean exists(ElContext current)
static String helpLink(ElContext current)