Repository navigation
APIs
Daniele Orlando edited this page May 30, 2016
·
10 revisions
function fluidxml($root?, array $options?); // Concise syntax for: new FluidXml(). function fluidify($file); // Concise syntax for: FluidXml::load(). function fluidns($id, $uri, $mode?); // Concise syntax for: new FluidNamespace().
class FluidXml ::load($file); ::new($root?, array $options?); // Alias of __construct(), requires PHP 7. __construct($root?, array $options?); ->namespace(...$namespace); ->namespaces(); ->__invoke(...$query); // Concise syntax. ->query(...$query); // Extended syntax. ->add($child, ...$optionals); // Concise. ->addChild($child, ...$optionals); // Extended. ->prepend($sibling, ...$optionals); // Concise. ->prependSibling($sibling, ...$optionals); // Extended. ->append($sibling, ...$optionals); // Concise. ->appendSibling($sibling, ...$optionals); // Extended. ->attr(...$arguments); // Concise. ->setAttribute(...$arguments); // Extended. ->text($text); // Concise. ->setText($text); // Extended. ->addText($text); ->cdata($text); // Concise. ->setCdata($text); // Extended. ->addCdata($text); ->remove(...$query); ->each(callable $fn); ->filter(callable $fn); ->times($times); ->times($times, callable $fn); ->size(); // Concise. ->length(); // Extended. ->array(); ->dom(); ->__toString(); // Concise. ->xml($strip = false); // Extended. ->html($strip = false); ->save($file, $strip = false);
class FluidNamespace __construct($id, $uri, $mode?); ->id(); ->uri(); ->mode(); ->querify($xpath);
The complete API documentation can be generated executing:
./support/tools/gendoc # Generated under 'documents/api/'.