code: @Override
      public final boolean hasNext() {
          resetToLastKey();
          // move back to element, if there was already an attribute found. In
          // this
          // case the current node was set to an attribute by resetToLastKey()
          if (mNextIndex > 0) {
              moveTo(getNode().getParentKey());
          }
          if (getNode().getKind() == IConstants.ELEMENT
              && mNextIndex < ((ElementNode)getNode()).getAttributeCount()) {
              moveTo(((ElementNode)getNode()).getAttributeKey(mNextIndex));
              mNextIndex += 1;
              return true;
          }
          resetToStartKey();
          return false;
      }
docs: {@inheritDoc}