當前位置: 首頁>>代碼示例>>PHP>>正文


PHP StorageProfilePeer::doSelect方法代碼示例

本文整理匯總了PHP中StorageProfilePeer::doSelect方法的典型用法代碼示例。如果您正苦於以下問題:PHP StorageProfilePeer::doSelect方法的具體用法?PHP StorageProfilePeer::doSelect怎麽用?PHP StorageProfilePeer::doSelect使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在StorageProfilePeer的用法示例。


在下文中一共展示了StorageProfilePeer::doSelect方法的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: retrieveExternalByPartnerId

 public static function retrieveExternalByPartnerId($partnerId, $con = null)
 {
     $criteria = new Criteria(StorageProfilePeer::DATABASE_NAME);
     $criteria->add(StorageProfilePeer::PARTNER_ID, $partnerId);
     $criteria->add(StorageProfilePeer::STATUS, array(StorageProfile::STORAGE_STATUS_AUTOMATIC, StorageProfile::STORAGE_STATUS_MANUAL), Criteria::IN);
     return StorageProfilePeer::doSelect($criteria, $con);
 }
開發者ID:richhl,項目名稱:kalturaCE,代碼行數:7,代碼來源:StorageProfilePeer.php

示例2: listByPartnerAction

 /**
  * @action listByPartner
  * @param KalturaPartnerFilter $filter
  * @param KalturaFilterPager $pager
  * @return KalturaStorageProfileListResponse
  */
 public function listByPartnerAction(KalturaPartnerFilter $filter = null, KalturaFilterPager $pager = null)
 {
     $c = new Criteria();
     if (!is_null($filter)) {
         $partnerFilter = new partnerFilter();
         $filter->toObject($partnerFilter);
         $partnerFilter->set('_gt_id', 0);
         $partnerCriteria = new Criteria();
         $partnerFilter->attachToCriteria($partnerCriteria);
         $partnerCriteria->setLimit(1000);
         $partnerCriteria->clearSelectColumns();
         $partnerCriteria->addSelectColumn(PartnerPeer::ID);
         $stmt = PartnerPeer::doSelectStmt($partnerCriteria);
         if ($stmt->rowCount() < 1000) {
             $partnerIds = $stmt->fetchAll(PDO::FETCH_COLUMN);
             $c->add(StorageProfilePeer::PARTNER_ID, $partnerIds, Criteria::IN);
         }
     }
     if (is_null($pager)) {
         $pager = new KalturaFilterPager();
     }
     $totalCount = StorageProfilePeer::doCount($c);
     $pager->attachToCriteria($c);
     $list = StorageProfilePeer::doSelect($c);
     $newList = KalturaStorageProfileArray::fromStorageProfileArray($list);
     $response = new KalturaStorageProfileListResponse();
     $response->totalCount = $totalCount;
     $response->objects = $newList;
     return $response;
 }
開發者ID:richhl,項目名稱:kalturaCE,代碼行數:36,代碼來源:StorageProfileService.php

示例3: prepareStorageProfilesForSort

 /**
  * Prepare storage profiles array for sorting
  *
  * @param int $partnerId
  */
 protected static function prepareStorageProfilesForSort($partnerId)
 {
     if (!is_null(self::$storageProfilesOrder)) {
         return;
     }
     $criteria = new Criteria();
     $criteria->add(StorageProfilePeer::PARTNER_ID, $partnerId);
     $criteria->add(StorageProfilePeer::DELIVERY_STATUS, StorageProfileDeliveryStatus::BLOCKED, Criteria::NOT_EQUAL);
     $criteria->addAscendingOrderByColumn(StorageProfilePeer::DELIVERY_PRIORITY);
     // Using doSelect instead of doSelectStmt for the ID column so that we can take adavntage of the query cache
     self::$storageProfilesOrder = array();
     $results = StorageProfilePeer::doSelect($criteria);
     foreach ($results as $result) {
         self::$storageProfilesOrder[] = $result->getId();
     }
 }
開發者ID:DBezemer,項目名稱:server,代碼行數:21,代碼來源:kFileSyncUtils.class.php

示例4: retrieveByPKs

 /**
  * Retrieve multiple objects by pkey.
  *
  * @param      array $pks List of primary keys
  * @param      PropelPDO $con the connection to use
  * @throws     PropelException Any exceptions caught during processing will be
  *		 rethrown wrapped into a PropelException.
  */
 public static function retrieveByPKs($pks, PropelPDO $con = null)
 {
     $objs = null;
     if (empty($pks)) {
         $objs = array();
     } else {
         $criteria = new Criteria(StorageProfilePeer::DATABASE_NAME);
         $criteria->add(StorageProfilePeer::ID, $pks, Criteria::IN);
         $objs = StorageProfilePeer::doSelect($criteria, $con);
     }
     return $objs;
 }
開發者ID:EfncoPlugins,項目名稱:Media-Management-based-on-Kaltura,代碼行數:20,代碼來源:BaseStorageProfilePeer.php

示例5: Criteria

            $passed = false;
        }
        if (!$passed) {
            break;
        }
    }
    if ($passed) {
        KalturaLog::notice("Drop folder [{$dropFolderId}] passed");
    } else {
        KalturaLog::err("Drop folder [{$dropFolderId}] failed");
    }
}
$storageProfileCriteria = new Criteria();
$storageProfileCriteria->add(StorageProfilePeer::STATUS, StorageProfile::STORAGE_STATUS_AUTOMATIC);
$storageProfileCriteria->add(StorageProfilePeer::PROTOCOL, StorageProfile::STORAGE_PROTOCOL_SFTP);
$storageProfiles = StorageProfilePeer::doSelect($storageProfileCriteria);
KalturaLog::debug("Storage profiles count [" . count($storageProfiles) . "]");
foreach ($storageProfiles as $storageProfile) {
    /* @var $storageProfile StorageProfile */
    $storageProfileId = $storageProfile->getId();
    $passed = true;
    $sftp = kFileTransferMgr::getInstance(kFileTransferMgrType::SFTP_SEC_LIB);
    /* @var $sftp sftpSecLibMgr */
    try {
        $sftp->login($storageProfile->getStorageUrl(), $storageProfile->getStorageUsername(), $storageProfile->getStoragePassword());
    } catch (Exception $e) {
        KalturaLog::err("Storage profile [{$storageProfileId}] login failed: " . $e->getMessage());
        continue;
    }
    $path = $storageProfile->getStorageBaseDir();
    $elements = $sftp->listDir($path);
開發者ID:DBezemer,項目名稱:server,代碼行數:31,代碼來源:testLibSec.php

示例6: listAction

 /**	
  * @action list
  * @param KalturaStorageProfileFilter $filter
  * @param KalturaFilterPager $pager
  * @return KalturaStorageProfileListResponse
  */
 public function listAction(KalturaStorageProfileFilter $filter = null, KalturaFilterPager $pager = null)
 {
     $c = new Criteria();
     if (!$filter) {
         $filter = new KalturaStorageProfileFilter();
     }
     $storageProfileFilter = new StorageProfileFilter();
     $filter->toObject($storageProfileFilter);
     $storageProfileFilter->attachToCriteria($c);
     $list = StorageProfilePeer::doSelect($c);
     if (!$pager) {
         $pager = new KalturaFilterPager();
     }
     $pager->attachToCriteria($c);
     $response = new KalturaStorageProfileListResponse();
     $response->totalCount = StorageProfilePeer::doCount($c);
     $response->objects = KalturaStorageProfileArray::fromDbArray($list, $this->getResponseProfile());
     return $response;
 }
開發者ID:DBezemer,項目名稱:server,代碼行數:25,代碼來源:StorageProfileService.php


注:本文中的StorageProfilePeer::doSelect方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。