PHP Класс NetworkName, glpi

represent the internet name of an element. It is compose of the name itself, its domain and one or several IP addresses (IPv4 and/or IPv6). An address can be affected to an item, or can be "free" to be reuse by another item (for instance, in case of maintenance, when you change the network card of a computer, but not its network information)
Наследование: extends FQDNLabel
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$canDeleteOnItemClean
$checkParentRights
$dohistory
$items_id
$itemtype From CommonDBChild
$mustBeAttached
$rightname

Защищенные свойства (Protected)

Свойство Тип Описание
$forward_entity_to

Открытые методы

Метод Описание
affectAddress ( $networkNameID, $items_id, $itemtype )
cleanDBonPurge ( )
countForItem ( CommonDBTM $item )
defineTabs ( $options = [] )
displayTabContentForItem ( CommonGLPI $item, $tabnum = 1, $withtemplate )
getHTMLTableCellsForItem ( HTMLTableRow $row = NULL, CommonDBTM $item = NULL, HTMLTableCell $father = NULL, array $options = [] )
getHTMLTableHeader ( $itemtype, HTMLTableBase $base, HTMLTableSuperHeader $super = NULL, HTMLTableHeader $father = NULL, array $options = [] )
getInternetNameFromID ( $ID ) : its Get the full name (internet name) of a NetworkName
getSearchOptions ( )
getSearchOptionsToAdd ( array &$tab, array $joinparams, $itemtype )
getTabNameForItem ( CommonGLPI $item, $withtemplate )
getTypeName ( $nb )
post_addItem ( )
post_updateItem ( $history = 1 )
post_workOnItem ( ) \brief Update IPAddress database Update IPAddress database to remove old IPs and add new ones.
showForItem ( CommonDBTM $item, $withtemplate ) \brief Show names for an item from its form Beware that the rendering can be different if readden from direct item form (ie : add new NetworkName, remove, .
showForm ( $ID, $options = [] ) : Nothing Print the network name form
showFormForNetworkPort ( $networkPortID )
unaffectAddressByID ( $networkNameID ) \brief dettach an address from an item
unaffectAddressesOfItem ( $items_id, $itemtype ) \brief dettach an address from an item

Описание методов

affectAddress() статический публичный Метод

static public affectAddress ( $networkNameID, $items_id, $itemtype )
$networkNameID
$items_id
$itemtype

cleanDBonPurge() публичный Метод

public cleanDBonPurge ( )

countForItem() статический публичный Метод

static public countForItem ( CommonDBTM $item )
$item CommonDBTM CommonDBTM object

defineTabs() публичный Метод

public defineTabs ( $options = [] )

displayTabContentForItem() статический публичный Метод

static public displayTabContentForItem ( CommonGLPI $item, $tabnum = 1, $withtemplate )
$item CommonGLPI

getHTMLTableCellsForItem() статический публичный Метод

static public getHTMLTableCellsForItem ( HTMLTableRow $row = NULL, CommonDBTM $item = NULL, HTMLTableCell $father = NULL, array $options = [] )
$row HTMLTableRow HTMLTableRow object (default NULL)
$item CommonDBTM CommonDBTM object (default NULL)
$father HTMLTableCell HTMLTableCell object (default NULL)
$options array array

getHTMLTableHeader() статический публичный Метод

static public getHTMLTableHeader ( $itemtype, HTMLTableBase $base, HTMLTableSuperHeader $super = NULL, HTMLTableHeader $father = NULL, array $options = [] )
$itemtype
$base HTMLTableBase HTMLTableBase object
$super HTMLTableSuperHeader HTMLTableSuperHeader object (default NULL
$father HTMLTableHeader HTMLTableHeader object (default NULL)
$options array array

getInternetNameFromID() статический публичный Метод

Get the full name (internet name) of a NetworkName
static public getInternetNameFromID ( $ID ) : its
$ID ID of the NetworkName
Результат its internet name, or empty string if invalid NetworkName

getSearchOptions() публичный Метод

public getSearchOptions ( )

getSearchOptionsToAdd() статический публичный Метод

static public getSearchOptionsToAdd ( array &$tab, array $joinparams, $itemtype )
$tab array array the array to fill
$joinparams array array
$itemtype

getTabNameForItem() публичный Метод

public getTabNameForItem ( CommonGLPI $item, $withtemplate )
$item CommonGLPI

getTypeName() статический публичный Метод

static public getTypeName ( $nb )

post_addItem() публичный Метод

public post_addItem ( )

post_updateItem() публичный Метод

public post_updateItem ( $history = 1 )

post_workOnItem() публичный Метод

\brief Update IPAddress database Update IPAddress database to remove old IPs and add new ones.
public post_workOnItem ( )

showForItem() статический публичный Метод

..) or if readden from item of the item (for instance from the computer form through NetworkPort::ShowForItem).
static public showForItem ( CommonDBTM $item, $withtemplate )
$item CommonDBTM CommonGLPI object
$withtemplate integer withtemplate param (default 0)

showForm() публичный Метод

Print the network name form
public showForm ( $ID, $options = [] ) : Nothing
$ID integer ID of the item
$options array - target for the Form - withtemplate template or basic computer
Результат Nothing (display)

showFormForNetworkPort() статический публичный Метод

static public showFormForNetworkPort ( $networkPortID )
$networkPortID

unaffectAddressByID() статический публичный Метод

The address can be unaffected, and remain "free"
static public unaffectAddressByID ( $networkNameID )
$networkNameID the id of the NetworkName

unaffectAddressesOfItem() статический публичный Метод

The address can be unaffected, and remain "free"
static public unaffectAddressesOfItem ( $items_id, $itemtype )
$items_id the id of the item
$itemtype the type of the item

Описание свойств

$canDeleteOnItemClean публичное статическое свойство

public static $canDeleteOnItemClean

$checkParentRights публичное статическое свойство

public static $checkParentRights

$dohistory публичное свойство

public $dohistory

$forward_entity_to защищенное статическое свойство

protected static $forward_entity_to

$items_id публичное статическое свойство

public static $items_id

$itemtype публичное статическое свойство

From CommonDBChild
public static $itemtype

$mustBeAttached публичное статическое свойство

public static $mustBeAttached

$rightname статическое публичное свойство

static public $rightname