当前位置: 首页>>代码示例>>PHP>>正文


PHP Schema::getKind方法代码示例

本文整理汇总了PHP中Schema::getKind方法的典型用法代码示例。如果您正苦于以下问题:PHP Schema::getKind方法的具体用法?PHP Schema::getKind怎么用?PHP Schema::getKind使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Schema的用法示例。


在下文中一共展示了Schema::getKind方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: determineMapper

 /**
  * Determine Mapper (early stage [draft] support for cross-entity upserts)
  *
  * @param Entity $obj_gds_entity
  * @return Mapper
  */
 protected function determineMapper(Entity $obj_gds_entity)
 {
     $str_this_kind = $obj_gds_entity->getKind();
     if (!isset($this->arr_kind_mappers[$str_this_kind])) {
         $this->arr_kind_mappers[$str_this_kind] = $this->createMapper();
         if ($this->obj_schema->getKind() != $str_this_kind) {
             $this->arr_kind_mappers[$str_this_kind]->setSchema($obj_gds_entity->getSchema());
         }
     }
     return $this->arr_kind_mappers[$str_this_kind];
 }
开发者ID:gonejack,项目名称:tumblr-images-datastore,代码行数:17,代码来源:Gateway.php

示例2: setSchema

 /**
  * Set the Schema for the Entity
  *
  * @param Schema $obj_schema
  * @return $this
  */
 public function setSchema(Schema $obj_schema)
 {
     $this->obj_schema = $obj_schema;
     $this->setKind($obj_schema->getKind());
     return $this;
 }
开发者ID:tomwalder,项目名称:php-gds,代码行数:12,代码来源:Entity.php

示例3: fetchEntityGroup

 /**
  * Fetch all of the entities in a particular group
  *
  * @param Entity $obj_entity
  * @return Entity[]
  */
 public function fetchEntityGroup(Entity $obj_entity)
 {
     $arr_results = $this->obj_gateway->withSchema($this->obj_schema)->withTransaction($this->str_transaction_id)->gql("SELECT * FROM `" . $this->obj_schema->getKind() . "` WHERE __key__ HAS ANCESTOR @ancestorKey", ['ancestorKey' => $obj_entity]);
     $this->str_last_cursor = $this->obj_gateway->getEndCursor();
     return $arr_results;
 }
开发者ID:tomwalder,项目名称:php-gds,代码行数:12,代码来源:Store.php


注:本文中的Schema::getKind方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。