This shows you the differences between two versions of the page.
— |
esmith:hostsdb [2019/06/05 19:48] (current) |
||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ===== esmith:: | ||
+ | | ||
+ | |||
+ | In a root terminal you can do the command below if you want to display the up-to-date content | ||
+ | perldoc -U esmith:: | ||
+ | |||
+ | ===== SYNOPSIS ===== | ||
+ | use esmith:: | ||
+ | my $hosts = esmith:: | ||
+ | | ||
+ | # everything else works just like esmith:: | ||
+ | | ||
+ | # these methods are added | ||
+ | my @hosts | ||
+ | my @new_hosts = $hosts-> | ||
+ | |||
+ | ===== DESCRIPTION ===== | ||
+ | This module provides an abstracted interface to the esmith hosts database. | ||
+ | Unless otherwise noted, esmith:: | ||
+ | |||
+ | ==== Overridden methods ==== | ||
+ | |||
+ | ==== open ==== | ||
+ | Like esmith:: | ||
+ | |||
+ | ==== open_ro() ==== | ||
+ | |||
+ | Like esmith:: | ||
+ | |||
+ | ===== Additional Methods ===== | ||
+ | |||
+ | These methods are added be esmith:: | ||
+ | |||
+ | ==== hosts ==== | ||
+ | my @hosts = $hosts-> | ||
+ | |||
+ | Returns a list of all host records in the database. | ||
+ | |||
+ | ==== propogate_hosts ==== | ||
+ | my @new_hosts = $hosts-> | ||
+ | |||
+ | When the name of your e-smith machine changes, this will change the name of any hosts which also started with $old_name to use the $new_name. | ||
+ | |||
+ | Returns a list of the newly tranlsated host records. | ||
+ | |||
+ | $db-> | ||
+ | |||
+ | Given a domain name (as a string), finds any hosts which match it and return them as a list of record objects. | ||
+ | ===== AUTHOR ===== | ||
+ | SME Server Developers < | ||
+ | |||
+ | {{tag> neth-development sme-development }} | ||