org.eclipse.equinox.p2.repository.artifact

## Class ArtifactKeyQuery

- java.lang.Object
- - org.eclipse.equinox.p2.query.ExpressionMatchQuery<IArtifactKey>
  - - org.eclipse.equinox.p2.repository.artifact.ArtifactKeyQuery

All Implemented Interfaces:
  IQueryWithIndex<IArtifactKey>, IMatchQuery<IArtifactKey>, IQuery<IArtifactKey>

    public final class ArtifactKeyQuery
    extends ExpressionMatchQuery<IArtifactKey>

A general purpose query for matching `IArtifactKey` instances that satisfy various criteria.

Since:
  2.0

### Field Summary

Fields
`static ArtifactKeyQuery` `ALL_KEYS` A singleton artifact key query that will always match every artifact key in the given `IQueryable`.

### Constructor Summary

Constructors
Constructor and Description
`ArtifactKeyQuery(IArtifactKey key)` Creates an artifact key query that will match any key equal to the provided key
`ArtifactKeyQuery(String classifier, String id, VersionRange range)` Pass the id and/or version range to match IArtifactKeys against.

### Method Summary

### Methods inherited from class org.eclipse.equinox.p2.query.ExpressionMatchQuery

`getContext, getExpression, getMatchingClass, isMatch, perform, perform, postPerform, prePerform, setIndexProvider`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Field Detail

#### ALL_KEYS

    public static final ArtifactKeyQuery ALL_KEYS

A singleton artifact key query that will always match every artifact key in the given `IQueryable`.

### Constructor Detail

#### ArtifactKeyQuery

    public ArtifactKeyQuery(String classifier,
                            String id,
                            VersionRange range)

Pass the id and/or version range to match IArtifactKeys against. Passing null results in matching any id/version

Parameters:
  `classifier` - The artifact key classifier, or `null`
  `id` - The artifact key id, or `null`
  `range` - A version range, or `null`

#### ArtifactKeyQuery

    public ArtifactKeyQuery(IArtifactKey key)

Creates an artifact key query that will match any key equal to the provided key

Parameters:
  `key` - the input key to test for equality in the query