ts3phpframework
Loading...
Searching...
No Matches
PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json Class Reference
Inheritance diagram for PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json:
PlanetTeamSpeak\TeamSpeak3Framework\Viewer\ViewerInterface

Public Member Functions

 __construct (array &$data=[])
 fetchObject (Node $node, array $siblings=[])
 toString ()
 __toString ()

Protected Member Functions

 getId ()
 getParent ()
 getLevel ()
 getType ()
 getClass ()
 getSpacerType ()
 getName ()
 getProps ()
 getImage ()

Protected Attributes

array $data
Node $currObj = null
array $currSib = null
int $lastLvl = 0

Detailed Description

Definition at line 21 of file Json.php.

Constructor & Destructor Documentation

◆ __construct()

PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::__construct ( array & $data = [])

The Json constructor.

Parameters
array$data
Returns
Json

Definition at line 59 of file Json.php.

Member Function Documentation

◆ __toString()

PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::__toString ( )

Returns a string representation of this node.

Returns
string

Definition at line 421 of file Json.php.

◆ fetchObject()

PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::fetchObject ( Node $node,
array $siblings = [] )

Assembles an stdClass object for the current element.

Parameters
Node$node
array$siblings
Returns
string

Implements PlanetTeamSpeak\TeamSpeak3Framework\Viewer\ViewerInterface.

Definition at line 72 of file Json.php.

◆ getClass()

PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::getClass ( )
protected

Returns a string for the current corpus element which can be used as an HTML class property. If the current node is a channel spacer the class string will contain additional class names to allow further customization of the content via CSS.

Returns
string

Definition at line 174 of file Json.php.

◆ getId()

PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::getId ( )
protected

Returns the ID of the current element.

Returns
false|string

Definition at line 102 of file Json.php.

◆ getImage()

PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::getImage ( )
protected

Returns the status icon URL of the current element.

Returns
string

Definition at line 401 of file Json.php.

◆ getLevel()

PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::getLevel ( )
protected

Returns the level of the current element.

Returns
integer

Definition at line 136 of file Json.php.

◆ getName()

PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::getName ( )
protected

Returns a string for the current corpus element which contains the display name for the current TeamSpeak_Node_Abstract object.

Returns
string

Definition at line 263 of file Json.php.

◆ getParent()

PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::getParent ( )
protected

Returns the parent ID of the current element.

Returns
string

Definition at line 120 of file Json.php.

◆ getProps()

PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::getProps ( )
protected

Returns the parent ID of the current element.

Returns
stdClass

Definition at line 290 of file Json.php.

◆ getSpacerType()

PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::getSpacerType ( )
protected

Returns an individual type for a spacer.

Returns
string

Definition at line 228 of file Json.php.

◆ getType()

PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::getType ( )
protected

Returns a single type identifier for the current element.

Returns
string

Definition at line 152 of file Json.php.

◆ toString()

PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::toString ( )

Returns a string representation of this node.

Returns
string

Definition at line 411 of file Json.php.

Member Data Documentation

◆ $currObj

Node PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::$currObj = null
protected

Definition at line 35 of file Json.php.

◆ $currSib

array PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::$currSib = null
protected

Definition at line 43 of file Json.php.

◆ $data

array PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::$data
protected

Definition at line 28 of file Json.php.

◆ $lastLvl

int PlanetTeamSpeak\TeamSpeak3Framework\Viewer\Json::$lastLvl = 0
protected

Definition at line 51 of file Json.php.


The documentation for this class was generated from the following file: