Skip to end of metadata
Go to start of metadata

Use the updateDeviceListForDiskSafe API to refresh the list of devices on a Disk Safe.

########====CDP Server Configuration Start====######## #set CDP server host name $HOST="10.230.131.25"; #set CDP server to access API $PORT="9443"; #set CDP user $USER="admin"; #set CDP user password $PASS="admin"; ########====CDP Server Configuration End====######## #sample Device class Class Device{ public $contentID; public $mountPoint; public $enabled; } /*$newDevice = new Device(); $newDevice->contentID = "587C436D7C43454A";# the device object can have either mount point or contentID $newDevice->enabled = true;# default state for this property is true*/ $newDevice2 = new Device(); $newDevice2->mountPoint = "/";# the device object can have either mount point or contentID $newDevice2->enabled = true;# default state for this property is true $newDevice3 = new Device(); $newDevice3->mountPoint = "/extraDisk";# the device object can have either mount point or contentID $newDevice4->enabled = true;# default state for this property is true $deviceList = array($newDevice2,$newDevice3); #sample DiskSafe class Class DiskSafe{ public $id; public $diskSafeAttributeMap; } $diskSafe = new DiskSafe(); $diskSafe->id = "0bd90c9b-fc2c-44ed-8716-2429f98a4e7b";# example disksafe id $diskSafe->diskSafeAttributeMap =array(); #Refresh the list of devices on a disk safe. try{ $client = new soapclient("https://$HOST:$PORT/DiskSafe?wsdl", array('login'=>"$USER", 'password'=>"$PASS", 'trace'=>1 ) ); $response = $client->updateDeviceListForDiskSafe(array('diskSafe'=>$diskSafe, 'deviceList'=>$deviceList); var_dump($response); echo "Successfully executed updateDeviceListForDiskSafe\n"; } catch (SoapFault $exception) { echo $exception; }

Labels:
None
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.