code: protected function getAttributeByNames($attrNames = array())
      {
          if (empty($attrNames)) {
              return $this->arrAttributes;
          }
  
          $result = array();
          foreach ($attrNames as $attributeName) {
              $result[$attributeName] = $this->arrAttributes[$attributeName];
          }
  
          return $result;
      }
docs: Retrieve all attributes with the given names.
  
  @param string[] $attrNames The attribute names, if empty all attributes will be returned.
  
  @return IAttribute[]