- Author
- Lluis TurrĂ³ Cutiller lluis.nosp@m.@tur.nosp@m.ro.or.nosp@m.g
Definition at line 44 of file WebContext.java.
◆ createFolders()
static boolean org.turro.elephant.web.context.WebContext.createFolders |
( |
Path |
relativePath | ) |
|
|
static |
Definition at line 350 of file WebContext.java.
351 File folder = Path.of(ElephantContext.getRealPath(
"/"), relativePath.toString()).toFile();
352 if(!folder.exists()) {
354 folder.toPath().resolve(
CONTEXT_FOLDER).resolve(CONTEXT_REPOSITORY).toFile().mkdirs();
static final String CONTEXT_FOLDER
◆ existsConf()
static boolean org.turro.elephant.web.context.WebContext.existsConf |
( |
Path |
path | ) |
|
|
static |
Definition at line 316 of file WebContext.java.
317 Path real = Path.of(ElephantContext.getRealPath(path.toString()),
319 return real.toFile().exists();
◆ getElement()
WebElement org.turro.elephant.web.context.WebContext.getElement |
( |
| ) |
|
◆ getElementInstance()
IElement org.turro.elephant.web.context.WebContext.getElementInstance |
( |
| ) |
|
◆ getI18nKey()
String org.turro.elephant.web.context.WebContext.getI18nKey |
( |
| ) |
|
◆ getImage()
String org.turro.elephant.web.context.WebContext.getImage |
( |
| ) |
|
◆ getLangs()
Set<String> org.turro.elephant.web.context.WebContext.getLangs |
( |
| ) |
|
◆ getLangsStr()
String org.turro.elephant.web.context.WebContext.getLangsStr |
( |
| ) |
|
◆ getLayout()
WebLayout org.turro.elephant.web.context.WebContext.getLayout |
( |
| ) |
|
◆ getName()
String org.turro.elephant.web.context.WebContext.getName |
( |
| ) |
|
Definition at line 144 of file WebContext.java.
145 if(!Strings.isBlank(i18nKey)) {
146 return I_.get(i18nKey);
150 "_" + I_.api().used().getLanguage(),
151 getNames().values().iterator().next());
Map< String, String > getNames()
◆ getNames()
Map<String, String> org.turro.elephant.web.context.WebContext.getNames |
( |
| ) |
|
◆ getOrder()
String org.turro.elephant.web.context.WebContext.getOrder |
( |
| ) |
|
◆ getPage()
WebPage org.turro.elephant.web.context.WebContext.getPage |
( |
| ) |
|
◆ getRedirect()
String org.turro.elephant.web.context.WebContext.getRedirect |
( |
| ) |
|
◆ getRole()
String org.turro.elephant.web.context.WebContext.getRole |
( |
| ) |
|
◆ getTarget()
String org.turro.elephant.web.context.WebContext.getTarget |
( |
| ) |
|
◆ getWebTag()
String org.turro.elephant.web.context.WebContext.getWebTag |
( |
| ) |
|
◆ inheritFrom()
Definition at line 294 of file WebContext.java.
295 WebContext wc =
new WebContext();
296 wc.setShowInNavigators(webContext.isShowInNavigators());
297 wc.setPrintContext(webContext.isPrintContext());
298 wc.setRole(webContext.getRole());
300 wc.setNoIndex(webContext.isNoIndex());
301 wc.setNoFollow(webContext.isNoFollow());
302 wc.setPrintVersion(webContext.isPrintVersion());
303 wc.setControlVersion(webContext.isControlVersion());
304 wc.setTraversalNavigation(webContext.isTraversalNavigation());
◆ isControlVersion()
boolean org.turro.elephant.web.context.WebContext.isControlVersion |
( |
| ) |
|
◆ isDynamic()
boolean org.turro.elephant.web.context.WebContext.isDynamic |
( |
| ) |
|
◆ isIcon()
boolean org.turro.elephant.web.context.WebContext.isIcon |
( |
| ) |
|
◆ isNoFollow()
boolean org.turro.elephant.web.context.WebContext.isNoFollow |
( |
| ) |
|
◆ isNoIndex()
boolean org.turro.elephant.web.context.WebContext.isNoIndex |
( |
| ) |
|
◆ isPrintContext()
boolean org.turro.elephant.web.context.WebContext.isPrintContext |
( |
| ) |
|
◆ isPrintVersion()
boolean org.turro.elephant.web.context.WebContext.isPrintVersion |
( |
| ) |
|
◆ isShowAlways()
boolean org.turro.elephant.web.context.WebContext.isShowAlways |
( |
| ) |
|
◆ isShowInNavigators()
boolean org.turro.elephant.web.context.WebContext.isShowInNavigators |
( |
| ) |
|
◆ isTraversalNavigation()
boolean org.turro.elephant.web.context.WebContext.isTraversalNavigation |
( |
| ) |
|
◆ isWikiPage()
boolean org.turro.elephant.web.context.WebContext.isWikiPage |
( |
| ) |
|
◆ loadFrom()
static WebContext org.turro.elephant.web.context.WebContext.loadFrom |
( |
Path |
path | ) |
|
|
static |
Definition at line 328 of file WebContext.java.
329 Path real = Path.of(ElephantContext.getRealPath(path.toString()),
331 try(Reader reader =
new FileReader(real.toFile())) {
332 return JsonConfiguration.read(reader, WebContext.class);
333 }
catch (IOException ex) {
334 Logger.getLogger(WebContext.class.getName()).log(Level.SEVERE,
null, ex);
◆ relativeRepository()
static String org.turro.elephant.web.context.WebContext.relativeRepository |
( |
| ) |
|
|
static |
◆ removeFrom()
static boolean org.turro.elephant.web.context.WebContext.removeFrom |
( |
Path |
path | ) |
|
|
static |
Definition at line 322 of file WebContext.java.
323 Path real = Path.of(ElephantContext.getRealPath(path.toString()),
325 return real.toFile().delete();
◆ repository()
static Path org.turro.elephant.web.context.WebContext.repository |
( |
Path |
path | ) |
|
|
static |
◆ saveTo()
static void org.turro.elephant.web.context.WebContext.saveTo |
( |
Path |
path, |
|
|
WebContext |
context |
|
) |
| |
|
static |
Definition at line 339 of file WebContext.java.
340 Path real = Path.of(ElephantContext.getRealPath(path.toString()),
342 try(Writer writer =
new FileWriter(real.toFile())) {
343 context.prepareSaving();
344 JsonConfiguration.write(writer, context);
345 }
catch (IOException ex) {
346 Logger.getLogger(WebContext.class.getName()).log(Level.SEVERE,
null, ex);
◆ setControlVersion()
void org.turro.elephant.web.context.WebContext.setControlVersion |
( |
boolean |
controlVersion | ) |
|
◆ setDynamic()
void org.turro.elephant.web.context.WebContext.setDynamic |
( |
boolean |
dynamic | ) |
|
◆ setElement()
void org.turro.elephant.web.context.WebContext.setElement |
( |
WebElement |
element | ) |
|
◆ setI18nKey()
void org.turro.elephant.web.context.WebContext.setI18nKey |
( |
String |
i18nKey | ) |
|
◆ setIcon()
void org.turro.elephant.web.context.WebContext.setIcon |
( |
boolean |
icon | ) |
|
◆ setImage()
void org.turro.elephant.web.context.WebContext.setImage |
( |
String |
image | ) |
|
◆ setLangs()
void org.turro.elephant.web.context.WebContext.setLangs |
( |
Set< String > |
langs | ) |
|
◆ setLangsStr()
void org.turro.elephant.web.context.WebContext.setLangsStr |
( |
String |
langs | ) |
|
Definition at line 258 of file WebContext.java.
260 this.langs.addAll(Strings.csvToList(langs));
◆ setLayout()
void org.turro.elephant.web.context.WebContext.setLayout |
( |
WebLayout |
layout | ) |
|
◆ setNames()
void org.turro.elephant.web.context.WebContext.setNames |
( |
Map< String, String > |
names | ) |
|
◆ setNoFollow()
void org.turro.elephant.web.context.WebContext.setNoFollow |
( |
boolean |
noFollow | ) |
|
◆ setNoIndex()
void org.turro.elephant.web.context.WebContext.setNoIndex |
( |
boolean |
noIndex | ) |
|
◆ setOrder()
void org.turro.elephant.web.context.WebContext.setOrder |
( |
String |
order | ) |
|
◆ setPage()
void org.turro.elephant.web.context.WebContext.setPage |
( |
WebPage |
page | ) |
|
◆ setPrintContext()
void org.turro.elephant.web.context.WebContext.setPrintContext |
( |
boolean |
printContext | ) |
|
◆ setPrintVersion()
void org.turro.elephant.web.context.WebContext.setPrintVersion |
( |
boolean |
printVersion | ) |
|
◆ setRedirect()
void org.turro.elephant.web.context.WebContext.setRedirect |
( |
String |
redirect | ) |
|
◆ setRole()
void org.turro.elephant.web.context.WebContext.setRole |
( |
String |
role | ) |
|
◆ setShowAlways()
void org.turro.elephant.web.context.WebContext.setShowAlways |
( |
boolean |
showAlways | ) |
|
◆ setShowInNavigators()
void org.turro.elephant.web.context.WebContext.setShowInNavigators |
( |
boolean |
showInNavigators | ) |
|
Definition at line 68 of file WebContext.java.
69 this.showInNavigators = showInNavigators;
◆ setTarget()
void org.turro.elephant.web.context.WebContext.setTarget |
( |
String |
target | ) |
|
◆ setTraversalNavigation()
void org.turro.elephant.web.context.WebContext.setTraversalNavigation |
( |
boolean |
traversalNavigation | ) |
|
Definition at line 84 of file WebContext.java.
85 this.traversalNavigation = traversalNavigation;
◆ setWebTag()
void org.turro.elephant.web.context.WebContext.setWebTag |
( |
String |
webTag | ) |
|
◆ CONTEXT_FOLDER
final String org.turro.elephant.web.context.WebContext.CONTEXT_FOLDER = "_internal" |
|
static |
The documentation for this class was generated from the following file: