[Mulgara-svn] r1483 - trunk/src/jar/resolver-lucene/java/org/mulgara/resolver/lucene
ronald at mulgara.org
ronald at mulgara.org
Thu Feb 12 18:00:03 UTC 2009
Author: ronald
Date: 2009-02-12 10:00:02 -0800 (Thu, 12 Feb 2009)
New Revision: 1483
Modified:
trunk/src/jar/resolver-lucene/java/org/mulgara/resolver/lucene/FullTextStringIndexTuples.java
Log:
Minor code tweaks: no need for fully-qualified class name for imported class,
and classes can be compared using == .
Modified: trunk/src/jar/resolver-lucene/java/org/mulgara/resolver/lucene/FullTextStringIndexTuples.java
===================================================================
--- trunk/src/jar/resolver-lucene/java/org/mulgara/resolver/lucene/FullTextStringIndexTuples.java 2009-02-12 17:59:56 UTC (rev 1482)
+++ trunk/src/jar/resolver-lucene/java/org/mulgara/resolver/lucene/FullTextStringIndexTuples.java 2009-02-12 18:00:02 UTC (rev 1483)
@@ -378,15 +378,15 @@
return false;
}
- public Annotation getAnnotation(Class<? extends org.mulgara.store.tuples.Annotation> annotationClass) throws TuplesException {
+ public Annotation getAnnotation(Class<? extends Annotation> annotationClass) throws TuplesException {
// the object (lucene query string) is required when a score is requested
- if (annotationClass.equals(MandatoryBindingAnnotation.class) &&
+ if (annotationClass == MandatoryBindingAnnotation.class &&
objectElement instanceof Variable && constraint.getScoreVar() != null) {
return new MandatoryBindingAnnotation(new Variable[] { (Variable)objectElement });
}
// support re-ordering the variables so any variables can be bound in the prefix
- if (annotationClass.equals(DefinablePrefixAnnotation.class)) {
+ if (annotationClass == DefinablePrefixAnnotation.class) {
return new DefinablePrefixAnnotation() {
public void definePrefix(Set boundVars) throws TuplesException {
if (boundVars.contains(constraint.getScoreVar()))
More information about the Mulgara-svn
mailing list