Name
params (LzParam) — A utility class for manipulating name-value pairs
Description
LzParam provide utilities for manipulating name-value pairs.
For example, LzParam objects can be used to manage a name/value pairs for an
HTTP request.
Development Note
LzParam objects hold onto parameters (name/value pairs) and provide methods
and utilities to reserialize them. They are used whenever case matters for
keys or parameter names (objects don't work here...)
Details
Setters (1)
Setters for virtual properties, to be used with setAttribute. A setter may or may not have a corresponding getter method;
consult the Methods list in this section.
-
$hasdefaultattrs
Methods (15)
-
addObject()
-
<method name="addObject" args="o" />
public function addObject(o : Object);
Adds a series of name/value pairs from an object
-
addValue()
-
<method name="addValue" args="name, val, enc" />
public function addValue(name : String, val : String, enc : Boolean);
Adds a value. Does not replace existing entries with the same name.
-
clone()
-
<method name="clone" args="o" />
public function clone(o) : LzParam;
Returns a clone of this LzParam
-
construct()
-
<method name="construct" args="parent, args" />
private function construct(parent, args);
-
createChildren()
-
<method name="createChildren" args="children" />
private function createChildren(children);
-
findKey()
-
<method name="findKey" args="name" />
private function findKey(name);
-
getNames()
-
<method name="getNames" />
public function getNames();
Get a list of all names, not necessarily in order
-
getValue()
-
<method name="getValue" args="name" />
public function getValue(name : String);
-
getValueNoCase()
-
<method name="getValueNoCase" args="name" />
public function getValueNoCase(name : String);
Get a value by name irrespective of case.
-
parseQueryString()
-
<method name="parseQueryString" args="query" />
public function parseQueryString(query) : Object;
Parse a URL query string, returns an object with key-value pairs
-
remove()
-
<method name="remove" args="name" />
public function remove(name : String);
Remove specified value by name or all values if null
-
serialize()
-
<method name="serialize" args="sep, delim, uriencode" />
public function serialize(sep : String, delim : String, uriencode : Boolean);
Returns a string representation using the current separator and delimiter
-
setDelimiter()
-
<method name="setDelimiter" args="d" />
public function setDelimiter(d : String) : String;
Set delimiter string used between records in serialize();
-
setSeparator()
-
<method name="setSeparator" args="s" />
public function setSeparator(s : String);
Set separator string used between name/value pairs in each record in
serialize();
-
setValue()
-
<method name="setValue" args="name, val, enc" />
public function setValue(name : String, val : String, enc : Boolean);
Sets a value. Replaces existing entries with the same name.
Prototype Properties (1)
-
toString
-
<attribute name="toString" />
LZX Synopsis
<class name="
LzParam" extends="
LzNode
">
<attribute name="
dlm
" />
<attribute name="
sep
" />
<method name="
addValue
" args="
name,
val,
enc" />
<method name="
clone
" args="
o" />
<method name="
construct
" args="
parent,
args" />
<method name="
findKey
" args="
name" />
<method name="
getValue
" args="
name" />
<method name="
remove
" args="
name" />
<method name="
serialize
" args="
sep,
delim,
uriencode" />
<method name="
setValue
" args="
name,
val,
enc" />
</class>
JavaScript Synopsis
private
LzParam extends
LzNode
{
prototype public function
addObject
(
o : Object);
prototype public function
addValue
(
name : String,
val : String,
enc : Boolean);
prototype public function
clone
(
o) :
LzParam;
prototype private function
construct
(
parent,
args);
prototype private function
findKey
(
name);
prototype public function
getValue
(
name : String);
prototype public function
remove
(
name : String);
prototype public function
serialize
(
sep : String,
delim : String,
uriencode : Boolean);
prototype public function
setDelimiter
(
d : String) :
String;
prototype public function
setValue
(
name : String,
val : String,
enc : Boolean);
}