public class INFO extends ProcessorModule
ProcessorModule.GetNodeListFunction, ProcessorModule.ProcessFunction, ProcessorModule.ReplaceFunction| Modifier and Type | Field and Description |
|---|---|
(package private) Hashtable<String,SortedVector> |
DirCache |
(package private) String |
documentroot |
static int |
Dutch |
static int |
English |
static int |
Not |
(package private) Random |
rnd |
PARAM_PAGEINFO, PARAMS_PAGEINFOconfigurationPath, getMaintainerFunction, getVersionFunction, properties, STATE_START_TIMEdescription, guiName, namefunctions, getFunctions| Constructor and Description |
|---|
INFO()
Constructor for
|
| Modifier and Type | Method and Description |
|---|---|
(package private) String |
doBrowser(PageInfo sp,
StringTokenizer tok)
Returns data about the user's browser.
Valid options are: OS : returns the operating system. |
(package private) Vector |
doColor(StringTokenizer tok)
Returns a list of color names and their RGB values.
|
(package private) Vector |
doColor16()
Returns a list of the 16 windows color names and their RGB values.
|
(package private) Vector |
doColorBasic()
Returns a list of basic color names and their RGB values.
|
(package private) Vector |
doColorSpectrum()
Returns a list of primary and secondary color names and their RGB values.
|
(package private) String |
doEscape(PageInfo sp,
StringTokenizer tok)
Converts a string into a string with 'escaped' quotes.
The argument for this command is the string to 'escape'. |
protected String |
doExists(PageInfo sp,
StringTokenizer tok)
Tests whether a given filename exists either as a directory, as a file, or as a path (depending on the subcommand given).
|
(package private) String |
doMemory(StringTokenizer tok)
This method is used to retrieve the amount of FREE MEMORY in either the JVM or the SYSTEM.
Valid options are: GETJVM (default) : returns free memory of the Java Virtual Machine GETSYS : return the free memory on the system B(default) :return memory in bytes KB: :return memory in kilo bytes MB: :return memory in mega bytes |
(package private) String |
doOs(PageInfo sp,
StringTokenizer tok)
Retrieve the name of the user's operating system.
|
(package private) String |
doParamDecode(PageInfo sp,
StringTokenizer tok)
Converts an URL-encoded string into a ASCII string.
The argument for this command is the string to decode. |
(package private) String |
doParamEncode(PageInfo sp,
StringTokenizer tok)
Converts an ASCII string into a URL-encoded string.
The argument for this command is the string to encode. |
(package private) String |
doParseTime(StringTokenizer tok)
takes a time in several formats and creates a time from it
|
(package private) String |
doRandom(PageInfo sp,
StringTokenizer tok)
Returns a random number in a specified range.
|
(package private) Vector |
doRange(StringTokenizer tok)
Returns a continues range of values with two set numerical boundaries and a step-increase, or
the range of characters of the alphabet.
|
(package private) String |
doRelTime(StringTokenizer tok)
This method is used to retrieve time related info from a relative time value.
|
(package private) Vector |
doScanDate(PageInfo sp,
StringTagger tagger)
Deprecated.
hereditary code. Should be dropped or adapted.
|
(package private) String |
doString(StringTokenizer tok)
Performs tests on strings.
|
(package private) String |
doTime(StringTokenizer tok)
Formats either the current or a given timevalue according to a specified format.
|
(package private) String |
doTimeFormat(StringTokenizer tok,
boolean inSec)
Formats either the current or a given timevalue according to a specified format.
|
(package private) String |
doUser(PageInfo sp,
StringTokenizer tok)
Returns information on the user
Valid options are:
NAME, which returns the username in SCAN HOSTNAME, which returns the name of the remote host (visiting) in SCAN IPNUMBER, which returns the ipnumber of the remote host(visiting) in SCAN SECLEVEL, which returns current security level in SCAN REQUEST_URI, which returns the path of the file requested in SCAN BACK, which returns the name of the page visted befote the current page, notice not supported by all browsers COUNTRY, which returns the country name of the remote host ( mmbase.nl -> nl; mmbase.org-> org ) DOMAIN, which returns the domain name of the remote host INDOMAIN, which returns YES when remote host has the same domain as us otherwise it returns NO in SCAN |
(package private) SortedVector |
getDirTimes(File scanfile)
Retrieves the creation times of all directories under a specific path
whose names are 10 characters long.
|
List<String> |
getList(PageInfo sp,
StringTagger tagger,
String value)
Generate a list of values from a command to the processor.
|
String |
getModuleInfo()
Returns a description of the module.
|
protected Map |
getProperties(String propertytable)
Returns the properties to the subclass.
|
protected String |
getProperty(String name,
String var)
Returns one propertyvalue to the subclass (original in Module).
|
void |
init()
Initializes the module.
|
boolean |
process(PageInfo sp,
Hashtable cmds,
Hashtable vars)
Execute the commands provided in the form values.
|
String |
replace(PageInfo sp,
String cmds)
Handle a $MOD command.
|
(package private) SortedVector |
revertVector(SortedVector src)
Reverse the order of a list of values
|
getListBuilder, getNodeList, onload, reload, replace, unloadaddInitParameters, getInitParameter, getInitParameter, getInitParameter, getInitParameters, getInitParameters, getMaintainer, getModule, getModule, getModule, getModule, getModuleLoader, getModuleReader, getModuleReader, getModules, getState, getStates, getVersion, hasModule, hasStarted, loadInitParameters, loadInitParameters, maintainance, setInitParameter, setMaintainer, setState, setVersion, shutdown, shutdownModules, startModule, startModulesgetDefaultLocale, getDescription, getDescription, getGUIName, getGUIName, getLocalizedDescription, getLocalizedGUIName, getName, setDescription, setDescription, setGUIName, setGUIName, setLocalizedDescription, setLocalizedGUIName, setNameaddFunction, createParameters, getFunction, getFunctions, getFunctionValue, newFunctionInstancepublic static final int Not
public static final int Dutch
public static final int English
Random rnd
String documentroot
Hashtable<String,SortedVector> DirCache
public void init()
init in class ProcessorModuleprotected String getProperty(String name, String var)
public List<String> getList(PageInfo sp, StringTagger tagger, String value)
getList in class ProcessorModulesp - the current page contexttagger - the parameters (name-value pairs) belonging to the command to processvalue - the command to processVector containing the requested values.ParseExceptionpublic boolean process(PageInfo sp, Hashtable cmds, Hashtable vars)
process in class ProcessorModulesp - the current page contextcmds - the command to processvars - the variables to processfalsepublic String replace(PageInfo sp, String cmds)
replace in class ProcessorModulesp - the current page contextcmds - the command to processString with the command's result valueString doParseTime(StringTokenizer tok)
tok - the processing command's argumentsString doTimeFormat(StringTokenizer tok, boolean inSec)
tok - the processing command's argumentsinSec - if true, the timevalue is in seconds instead of millisecondsString containing the time in the specified formatString doString(StringTokenizer tok)
tok - StringTokenizer with the rest of the cmd.true if the test succeedsString doEscape(PageInfo sp, StringTokenizer tok)
sp - the current page contexttok - the StringTokenizer containing the subsequent cmd argument tokens.String which is the converted valueString doParamEncode(PageInfo sp, StringTokenizer tok)
sp - the current page contexttok - the StringTokenizer containing the subsequent cmd argument tokens.String which is the converted valueString doParamDecode(PageInfo sp, StringTokenizer tok)
sp - the current page contexttok - the StringTokenizer containing the subsequent cmd argument tokens.String which is the converted valueString doOs(PageInfo sp, StringTokenizer tok)
sp - the current page contexttok - the StringTokenizer containing the subsequent cmd argument tokens.String which is the converted valueString doRandom(PageInfo sp, StringTokenizer tok)
sp - the current page context
param tok the StringTokenizer containing the subsequent cmd argument tokens.String containing a random numberString doBrowser(PageInfo sp, StringTokenizer tok)
sp - the current page contexttok - The StringTokenizer containing the subsequent cmd argument tokens.String containing the resultString doUser(PageInfo sp, StringTokenizer tok)
tok - StringTokenizer with the rest of the cmd.sp - the scanpageprotected Map getProperties(String propertytable)
Vector doRange(StringTokenizer tok)
tok - The StringTokenizer containing the subsequent cmd argument tokens.String containing the resultVector doColor(StringTokenizer tok)
tok - The commands to be executedVector containing color names and RGB valuesVector doColorBasic()
Vector containing color names and RGB valuesVector doColorSpectrum()
Vector containing color names and RGB valuesVector doColor16()
Vector containing color names and RGB valuesString doTime(StringTokenizer tok)
tok - the processing command's argumentsinSec - if true, the timevalue is in seconds instead of millisecondsString containing the time in the specified formatpublic String getModuleInfo()
getModuleInfo in class ModuleString describing the module's function.String doRelTime(StringTokenizer tok)
tok - The StringTokenizer containing the subsequent cmd argument tokens.String doMemory(StringTokenizer tok)
tok - The StringTokenizer containing the subsequent cmd argument tokens.Vector doScanDate(PageInfo sp, StringTagger tagger)
sp - the current page contexttok - the commands to be executedVector containing color names and RGB valuesSortedVector revertVector(SortedVector src)
src - the source of values to reverseVector containing the reverse ordered listSortedVector getDirTimes(File scanfile)
scanfile - the path to searchVector containing the timesprotected String doExists(PageInfo sp, StringTokenizer tok)
sp - the current page contexttok - the commands to be executedString withe the value 'YES' if the check succeeded, 'NO' if it failed.MMBase 1.9-SNAPSHOT - ${javadoctimestamp}