Permission/PermissionUtils.php
public static function getClassAndField($subject, $optional = false)
    {
        /** @var null|SubjectIdentityInterface $subject */
        list($subject, $field) = static::getSubjectAndField($subject, $optional);

        $class = null !== $subject
            ? $subject->getType()
            : null;

        return [$class, $field];
    }
public static function getClassAndField($subject, $optional = false)
    {
        /** @var null|SubjectIdentityInterface $subject */
        list($subject, $field) = static::getSubjectAndField($subject, $optional);

        $class = null !== $subject
            ? $subject->getType()
            : null;

        return [$class, $field];
    }
public static function getClassAndField ( $ subject , $ optional = false ) { /** @var null|SubjectIdentityInterface $subject */ list ( $ subject , $ field ) = static :: getSubjectAndField ( $ subject , $ optional ) ; $ class = null !== $ subject ? $ subject -> getType ( ) : null ; return [ $ class , $ field ] ; }
Get the class and field.

@param null|FieldVote|object|string|SubjectIdentityInterface $subject  The subject instance or classname
@param bool                                                  $optional Check if the subject id optional

@return array
Get the class and field .