/**
  * Filter Descriptor with based on visibility.
  *
  * @param DescriptorAbstract $value
  *
  * @return DescriptorAbstract|null
  */
 public function filter($value)
 {
     if ($value instanceof VisibilityInterface && !$this->builder->isVisibilityAllowed($value->getVisibility())) {
         return null;
     }
     return $value;
 }