code: public final AbstractItem matches(final Filter filter, boolean allowUnavailable) throws SevereMessageStoreException
      {
          if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
              SibTr.entry(this, tc, "matches", new Object[] { filter, Boolean.valueOf(allowUnavailable) });
  
          AbstractItem foundItem = null;
          if (allowUnavailable || isAvailable())
          {
              if (!isExpired())
              {
                  AbstractItem item = getItem();
                  if (null == item)
                  {
                      if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
                          SibTr.debug(this, tc, "item does not exist");
                  }
                  else
                  {
                      try
                      {
                          if (null == filter || filter.filterMatches(item))
                          {
                              foundItem = item;
                          }
                      } catch (Exception e)
                      {
                          //No FFDC Code Needed.
                          // assume exception is false return
                      }
                  }
              }
          }
  
          if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
              SibTr.exit(this, tc, "matches", foundItem);
          return foundItem;
      }
docs: Version used by browse cursor as it can be set to allow matching
  unavailable items to be seen.
  
  @param filter
  @param allowUnavailable
  @throws SevereMessageStoreException