有没有办法从PHP SDK中获取Parse中的所有类?
问题描述:
I have an account on parse.com and i created some classes, such as products, users, roles, brands, ...etc
Is there a way to get a list of those classes using PHP-SDK?
Thanks.
我在 parse.com 我创建了一些类 strong>,例如产品,用户,角色,品牌等...... p>
是否有 使用PHP-SDK获取列表的方法 strong>? p>
谢谢。 p>
div>
答
You can use ParseSchema
class to access the list of classes you have created.
use Parse\ParseClient;
use Parse\ParseSchema;
$app_id = '';
$master_key = '';
$rest_key = '';
$parse = ParseClient::initialize( $app_id, $rest_key, $master_key );
$schemas = new ParseSchema();
$classes = $schemas->all();
var_dump($classes);