main/core/Security/Voter/FacetVoter.php
public function vote(TokenInterface $token, $object, array $attributes)
    {
        if ($object instanceof FieldFacetCollection) {
            //fields right management is done at the Panel level
            return $this->fieldFacetVote($object, $token, strtolower($attributes[0]));
        }

        if ($object instanceof PanelFacet) {
            return $this->panelFacetVote($object, $token, strtolower($attributes[0]));
        } elseif ($object instanceof Facet) {
            //no implementation yet
        }

        return VoterInterface::ACCESS_ABSTAIN;
    }
public function vote(TokenInterface $token, $object, array $attributes)
    {
        if ($object instanceof FieldFacetCollection) {
            //fields right management is done at the Panel level
            return $this->fieldFacetVote($object, $token, strtolower($attributes[0]));
        }

        if ($object instanceof PanelFacet) {
            return $this->panelFacetVote($object, $token, strtolower($attributes[0]));
        } elseif ($object instanceof Facet) {
            //no implementation yet
        }

        return VoterInterface::ACCESS_ABSTAIN;
    }
public function vote ( TokenInterface $ token , $ object , array $ attributes ) { if ( $ object instanceof FieldFacetCollection ) { //fields right management is done at the Panel level return $ this -> fieldFacetVote ( $ object , $ token , strtolower ( $ attributes [ 0 ] ) ) ; } if ( $ object instanceof PanelFacet ) { return $ this -> panelFacetVote ( $ object , $ token , strtolower ( $ attributes [ 0 ] ) ) ; } elseif ( $ object instanceof Facet ) { //no implementation yet } return VoterInterface :: ACCESS_ABSTAIN ; }
Attributes can either be "open" or "edit".

@param TokenInterface $token
@param $object
@param array $attributes
Attributes can either be open or edit .