public function validateToken($token)
    {
        if (is_string($token)) {
            $token = $this->decodeToken($token);
        }

        if (!isset($token->sdef) || !is_array($token->sdef) || count($token->sdef) !== 3) {
            throw new BadRequestHttpException('sdef should be a sub-definition identifier.');
        }
        list ($sbas_id, $record_id, $subdef) = $token->sdef;

        return array($sbas_id, $record_id, $subdef);
    }
public function validateToken($token)
    {
        if (is_string($token)) {
            $token = $this->decodeToken($token);
        }

        if (!isset($token->sdef) || !is_array($token->sdef) || count($token->sdef) !== 3) {
            throw new BadRequestHttpException('sdef should be a sub-definition identifier.');
        }
        list ($sbas_id, $record_id, $subdef) = $token->sdef;

        return array($sbas_id, $record_id, $subdef);
    }
public function validateToken ( $ token ) { if ( is_string ( $ token ) ) { $ token = $ this -> decodeToken ( $ token ) ; } if ( ! isset ( $ token -> sdef ) || ! is_array ( $ token -> sdef ) || count ( $ token -> sdef ) !== 3 ) { throw new BadRequestHttpException ( 'sdef should be a sub-definition identifier.' ) ; } list ( $ sbas_id , $ record_id , $ subdef ) = $ token -> sdef ; return array ( $ sbas_id , $ record_id , $ subdef ) ; }
Validate token and returns triplet containing sbas_id, record_id and subdef.

@param string|object $token
@return array
Validate token and returns triplet containing sbas_id record_id and subdef .