Zabbix map objects
use Zabbix::API::Map; # TODO write the rest
Handles \s-1CRUD\s0 for Zabbix map objects.
This is a subclass of \*(C`Zabbix::API::CRUDE\*(C'.
Specific mutator for the \*(C`selements\*(C' array. Setting the selements through this actually only has an effect on host type elements (that is, both elements that have the correct \*(C`elementtype\*(C' and elements that have a \*(C`host\*(C' element). All other types are ignored.
This method handles extraneous \*(C`host => Zabbix::API::Host\*(C' attributes in the selements array, transforming them into \*(C`elementid\*(C' and \*(C`elementtype\*(C' attributes (and setting the \*(C`label\*(C' attribute to the hostname if it isn't set already), and pushing the hosts to the server if they don't exist already. Overriden from \*(C`Zabbix::API::CRUDE\*(C'. ** \s-1WARNING\s0 ** Due to the way maps \s-1API\s0 calls are implemented in Zabbix, updating a map will delete it and create it anew. The \*(C`sysmapid\*(C' will change if you push an existing map.
The various integers representing map element types are implemented as constants:
MAP_ELEMENT_TYPE_HOST MAP_ELEMENT_TYPE_MAP MAP_ELEMENT_TYPE_TRIGGER MAP_ELEMENT_TYPE_HOSTGROUP MAP_ELEMENT_TYPE_IMAGE
Nothing is exported by default; you can use the tag \*(C`:map_element_types\*(C' (or import by name).
Zabbix::API::CRUDE.
Fabrice Gabolde <[email protected]>
Copyright (C) 2011 \s-1SFR\s0
This library is free software; you can redistribute it and/or modify it under the terms of the GPLv3.