All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.eclipse.equinox.p2.query.IMatchQuery Maven / Gradle / Ivy

The newest version!
/******************************************************************************* 
* Copyright (c) 2009, 2010 EclipseSource and others. All rights reserved. This
* program and the accompanying materials are made available under the terms of
* the Eclipse Public License v1.0 which accompanies this distribution, and is
* available at http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
*   EclipseSource - initial API and implementation
******************************************************************************/
package org.eclipse.equinox.p2.query;

/**
 * A query in which the elements can be evaluated by calling isMatch on. Each
 * element can be evaluated independently of all other elements.  Match queries
 * can be evaluated in parallel as each call {@link #isMatch(Object)} is mutually
 * exclusive from all other calls. 

* * @noimplement This interface is not intended to be implemented by clients. Clients * creating custom queries must extend {@link ExpressionMatchQuery}. * @deprecated If possible, use one of the predefined queries in {@link QueryUtil} or * use the {@link QueryUtil#createMatchQuery(String, Object...)} * to create a custom expression based query. If the query cannot be expressed using * the p2QL, then use a predefined or custom expression query as a first filter * (in worst case, use {@link QueryUtil#createIUAnyQuery()}) and then provide further filtering * like so:

 * for(iter = queryable.query(someExpressionQuery).iterator(); iter.hasNext();) {
 *   // do your match here
 * }
* @since 2.0 */ public interface IMatchQuery extends IQuery { /** * Returns whether the given object satisfies the parameters of this query. * * @param candidate The object to perform the query against * @return true if the unit satisfies the parameters * of this query, and false otherwise * * @noreference This method is not intended to be referenced by clients. * @since 2.0 */ public boolean isMatch(T candidate); }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy