}
if ($flag == true) {
    if (!isset($certPath)) {
        echo "\n\nIgnoring the Certificate Validation --Fake certificate - DO NOT DO THIS IN PRODUCTION.\n\n";
    }
    // login
    $service = VMware_VCloud_SDK_Service::getService();
    $service->login($server, array('username' => $user, 'password' => $pswd), $httpConfig, $sdkversion);
    $sdkExt = $service->createSDKExtensionObj();
    if (true === $list) {
        $ebt = $sdkExt->getEnabledBlockingTaskOperations();
        echo $ebt->export() . "\n";
        exit(0);
    }
    $ops = true === $dis ? null : $ops;
    $tl = new VMware_VCloud_API_TaskOperationListType();
    $tl->setOperation($ops);
    $ntl = $sdkExt->updateEnabledBlockingTaskOperations($tl);
    echo $ntl->export() . "\n";
} else {
    echo "\n\nLogin Failed due to certification mismatch.";
    return;
}
/**
 * Print the help message of the sample.
 */
function usage()
{
    echo "Usage:\n\n";
    echo "  [Description]\n";
    echo "     This sample demonstrates enabling or disabling blocking tasks.\n";
 /** 
  * Updates the blocking task operations which are enabled.
  *
  * @param VMware_VCloud_API_TaskOperationListType $list
  * @return VMware_VCloud_API_TaskOperationListType
  * @since Version 1.5.0
  */
 public function updateEnabledBlockingTaskOperations($list)
 {
     $url = $this->url . '/settings/blockingTask/operations';
     $list->set_tagName('vmext:BlockingTaskOperations');
     $type = VMware_VCloud_SDK_Constants::TASK_OPERATION_LIST_CONTENT_TYPE;
     return $this->svc->put($url, 200, $type, $list);
 }