Zabbix::API::Map -- Zabbix map objects
use Zabbix::API::Map; # TODO write the rest
Handles CRUD for Zabbix map objects.
This is a subclass of
Specific mutator for the
selements array. Setting the selements through this actually only has an effect on host type elements (that is, both elements that have the correct
elementtype and elements that have a
host element). All other types are ignored.
This method handles extraneous
host => Zabbix::API::Host attributes in the selements array, transforming them into
elementtype attributes (and setting the
label attribute to the hostname if it isn't set already), and pushing the hosts to the server if they don't exist already.
** WARNING ** Due to the way maps API calls are implemented in Zabbix, updating a map will delete it and create it anew. The
sysmapid 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
:map_element_types (or import by name).
Fabrice Gabolde <firstname.lastname@example.org>
Copyright (C) 2011 SFR
This library is free software; you can redistribute it and/or modify it under the terms of the GPLv3.