Public Member Functions | |
| String | getId () |
| IContext | getContext () |
| String | getType () |
| String | getTitle () |
| String | getName () |
| String | getExactName (String lang) |
| String | getName (String lang) |
| void | setName (String lang, String name) |
| String | getIcon () |
| void | setIcon (String icon) |
| String | getRedirection () |
| String | getTarget () |
| IElement | getDefaultElement () |
| IElement | getDefaultElement (String type) |
| Set< String > | getDefaultLocales () |
| String[] | getLocaleSufixes (String preferredLocale) |
| void | setConstructor (IConstructor constructor, String path) |
| String | getFullPath () |
| String | getWebPath () |
| String | getPath () |
| int | getLevel () |
| File | getFile () |
| IContext | getParent () |
| IContext[] | getAncestors () |
| IContext[] | getChildren () |
| IContext[] | getSiblings () |
| void | startConstruction () throws ServletException, IOException |
| IConstructor | getConstructor () |
| boolean | inPath (IContext context) |
IContext represents a single folder within web application context. Root IContext is site's. Root subfolders are context's children. Each context may have zero or more children.
Definition at line 32 of file IContext.java.
| IContext [] org.turro.elephant.context.IContext.getAncestors | ( | ) |
The returning array for this method has as the first element, the root context, and the last, the calling context.
Implemented in org.turro.elephant.impl.context.DefaultContext.
| IContext [] org.turro.elephant.context.IContext.getChildren | ( | ) |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| IConstructor org.turro.elephant.context.IContext.getConstructor | ( | ) |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| IContext org.turro.elephant.context.IContext.getContext | ( | ) |
Allows mixing IElement and IContext and get a reference to context.
Implemented in org.turro.elephant.impl.context.DefaultContext.
| IElement org.turro.elephant.context.IContext.getDefaultElement | ( | ) |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| IElement org.turro.elephant.context.IContext.getDefaultElement | ( | String | type | ) |
| type | Element's type. |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| Set<String> org.turro.elephant.context.IContext.getDefaultLocales | ( | ) |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| String org.turro.elephant.context.IContext.getExactName | ( | String | lang | ) |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| File org.turro.elephant.context.IContext.getFile | ( | ) |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| String org.turro.elephant.context.IContext.getFullPath | ( | ) |
Full path intention is to provide an easy way for creating absolute links, starting with a slash.
Implemented in org.turro.elephant.impl.context.DefaultContext.
| String org.turro.elephant.context.IContext.getIcon | ( | ) |
Returns the image representing this context.
Implemented in org.turro.elephant.impl.context.DefaultContext.
| String org.turro.elephant.context.IContext.getId | ( | ) |
Identifier is a unique value within Elephant web application.
Implemented in org.turro.elephant.impl.context.DefaultContext.
| int org.turro.elephant.context.IContext.getLevel | ( | ) |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| String [] org.turro.elephant.context.IContext.getLocaleSufixes | ( | String | preferredLocale | ) |
Locale sufixes is a combination of locales in a single request. It's composed by user selection (the cookie 'lang'), navigator preferences and context preferences. Default context's language, first place in getDefaultLocales(), is included as an empty string.
| preferredLocale | Locale that will take first place. |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| String org.turro.elephant.context.IContext.getName | ( | ) |
Context name is the text that shows in navigators. This method returns the same value than calling getName(null).
Implemented in org.turro.elephant.impl.context.DefaultContext.
| String org.turro.elephant.context.IContext.getName | ( | String | lang | ) |
Context name is the text that shows in navigators.
| lang | Specific locale |
lang locale. Implemented in org.turro.elephant.impl.context.DefaultContext.
| IContext org.turro.elephant.context.IContext.getParent | ( | ) |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| String org.turro.elephant.context.IContext.getPath | ( | ) |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| String org.turro.elephant.context.IContext.getRedirection | ( | ) |
When a context has a redirection it never gets selected, instead browser receives a redirection response.
Implemented in org.turro.elephant.impl.context.DefaultContext.
| IContext [] org.turro.elephant.context.IContext.getSiblings | ( | ) |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| String org.turro.elephant.context.IContext.getTarget | ( | ) |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| String org.turro.elephant.context.IContext.getTitle | ( | ) |
Context title defaults to context name. Elements can override this value.
Implemented in org.turro.elephant.impl.context.DefaultContext.
| String org.turro.elephant.context.IContext.getType | ( | ) |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| String org.turro.elephant.context.IContext.getWebPath | ( | ) |
Works as getFullPath method but takes into account redirections
Implemented in org.turro.elephant.impl.context.DefaultContext.
| boolean org.turro.elephant.context.IContext.inPath | ( | IContext | context | ) |
This method is used by navigators in order to check whether a context exists in currently selected context. Therefore a call like context.inPath(current) must return true if context is one of current ancestors.
| context | A context to check its path with. |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| void org.turro.elephant.context.IContext.setConstructor | ( | IConstructor | constructor, |
| String | path | ||
| ) |
This method gets authomatically called from ContextFactory. Its intention is to set constructor and context path.
| constructor | Constructor that generated context creation. |
| path | Context's relative path, starting with a slash or empty for root context. |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| void org.turro.elephant.context.IContext.setIcon | ( | String | icon | ) |
Sets the image that represents this context.
| icon | URL to icon. |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| void org.turro.elephant.context.IContext.setName | ( | String | lang, |
| String | name | ||
| ) |
Sets context's name in the given locale.
| lang | Specific locale. |
| name | Context name. |
Implemented in org.turro.elephant.impl.context.DefaultContext.
| void org.turro.elephant.context.IContext.startConstruction | ( | ) | throws ServletException, IOException |
Start construction should be aware of which layout is being used, in order to give an initialization code. This is done automatically by ILayoutManager, returned by ContextFactory.
| javax.servlet.ServletException | |
| java.io.IOException |
Implemented in org.turro.elephant.impl.context.DefaultContext.