Phraseanet PHP SDK API
Class

PhraseanetSDK\EntityManager

class EntityManager

Methods

__construct(APIGuzzleAdapter $adapter)

RepositoryInterface getRepository(string $name)

Get a repository by its name

EntityInterface getEntity(string $name)

Return a new entity by its name

EntityInterface HydrateEntity(EntityInterface $entity, stdClass $datas)

Hydrates an entity with datas

APIGuzzleAdapter getAdapter()

Return the client attached to this entity manager

Details

at line 29
public __construct(APIGuzzleAdapter $adapter)

Parameters

APIGuzzleAdapter $adapter

at line 40
public RepositoryInterface getRepository(string $name)

Get a repository by its name

Parameters

string $name

Return Value

RepositoryInterface

at line 57
public EntityInterface getEntity(string $name)

Return a new entity by its name

Parameters

string $name The name of the entity

Return Value

EntityInterface

at line 70
public EntityInterface HydrateEntity(EntityInterface $entity, stdClass $datas)

Hydrates an entity with datas

Parameters

EntityInterface $entity
stdClass $datas

Return Value

EntityInterface

at line 80
public APIGuzzleAdapter getAdapter()

Return the client attached to this entity manager

Return Value

APIGuzzleAdapter