PHP Class Tobscure\JsonApi\Util

Afficher le fichier Open project: tobscure/json-api Class Usage Examples

Méthodes publiques

Méthode Description
parseRelationshipPaths ( array $paths ) : array Parse relationship paths.

Method Details

parseRelationshipPaths() public static méthode

Given a flat array of relationship paths like: ['user', 'user.employer', 'user.employer.country', 'comments'] create a nested array of relationship paths one-level deep that can be passed on to other serializers: ['user' => ['employer', 'employer.country'], 'comments' => []]
public static parseRelationshipPaths ( array $paths ) : array
$paths array
Résultat array