Package com.codestreet.selector

Examples of com.codestreet.selector.ISelector


  public Collection getMessages(MessageFactory messageFactory, String selector) throws JMSException, IOException {
    final Collection messages = xmlHelper.fromXML(messageFactory, new FileInputStream(file));

    if (selector != null) {
      try {
        final ISelector selectorImpl = Selector.getInstance(selector);
        for (final Iterator iter = messages.iterator(); iter.hasNext();) {
          final Message message = (Message) iter.next();
          if (selectorImpl.eval(ValueProvider.valueOf(message), null) == Result.RESULT_FALSE) {
            iter.remove();
          }
        }
      } catch (InvalidSelectorException e) {
        throw new HermesException(e);
View Full Code Here

TOP

Related Classes of com.codestreet.selector.ISelector

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.