code: public Attribute getAttribute(String attrName) {
      Attribute attr = getCachedOwnAttrs().get(attrName);
      if (attr == null) {
        // look up attribute in parent entity
        EntityType extendsEntityType = getExtends();
        if (extendsEntityType != null) {
          attr = extendsEntityType.getAttribute(attrName);
        }
      }
      return attr;
    }
docs: Get attribute by name
  
  @return attribute or <tt>null</tt>