API Reference Guide > PHP XMLSERVICE Toolkit > iToolkit Service Class > Get Objects List Methods

Get Objects List Methods

getObjectList($Object, $Library, $Objecttype) - Enables you to work with a list of any objects in one library. This method is similar to the WRKOBJPDM command.

 

Arguments

Value

Description

$Object

*ALL - default

Object name

$Library

*LIBL - default

Library

$Objecttype

*ALL - default

Object type

Sample Code

Usage Example

$objlist->getObjectList('ZCC*', ‘ZENDSVR’ , '*ALL');
}
A PHP script that shows the usage of all User Space methods
<pre>
Display objects starting with ZCC* name in ZENDSVR library
<?php
include_once 'authorization.php';
include_once '../API/iToolkitService.php';
try {
         $ToolkitServiceObj  = ToolkitService::getInstance($db, $user, $pass);
     }
 catch (Exception $e) {              
    echo  $e->getMessage(), "\n";
    exit();
}
$ToolkitServiceObj->setToolkitServiceParams(array('InternalKey'=>"/tmp/$user"));
  
$objlist = new ObjectLists ($ToolkitServiceObj);
$inLib = "ZENDSVR";
try {
    $param_type_all = $objlist->getObjectList('ZCC*', $inLib , '*ALL');
}
catch (Exception $e)
{
    echo $e->getMessage();
    exit;
}
var_dump($param_type_all);
/* Do not use the disconnect() function for "state full" connection */
$ToolkitServiceObj->disconnect(); exit();
           
?>
</pre>

 

 

Read Also

  PHP XMLSERVICE Toolkit    
  iToolkit Service Class