From 2601903faaf2d25baba21063f6957b1abef672a4 Mon Sep 17 00:00:00 2001 From: mike Date: Wed, 27 Jun 2007 17:05:05 +0000 Subject: [PATCH] Use new Modifier objects for PQF translation rather than the old Vector hack. --- src/org/z3950/zing/cql/CQLTermNode.java | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/org/z3950/zing/cql/CQLTermNode.java b/src/org/z3950/zing/cql/CQLTermNode.java index 841c139..070955c 100644 --- a/src/org/z3950/zing/cql/CQLTermNode.java +++ b/src/org/z3950/zing/cql/CQLTermNode.java @@ -1,4 +1,4 @@ -// $Id: CQLTermNode.java,v 1.23 2007-06-06 12:22:01 mike Exp $ +// $Id: CQLTermNode.java,v 1.24 2007-06-27 17:05:05 mike Exp $ package org.z3950.zing.cql; import java.util.Properties; @@ -12,7 +12,7 @@ import java.util.Vector; * these must be provided - you can't have a qualifier without a * relation or vice versa. * - * @version $Id: CQLTermNode.java,v 1.23 2007-06-06 12:22:01 mike Exp $ + * @version $Id: CQLTermNode.java,v 1.24 2007-06-27 17:05:05 mike Exp $ */ public class CQLTermNode extends CQLNode { private String qualifier; @@ -109,11 +109,12 @@ public class CQLTermNode extends CQLNode { throw new UnknownRelationException(rel); attrs.add(attr); - String[] mods = relation.getModifiers(); - for (int i = 0; i < mods.length; i++) { - attr = config.getProperty("relationModifier." + mods[i]); + Vector mods = relation.getModifiers(); + for (int i = 0; i < mods.size(); i++) { + String type = mods.get(i).type; + attr = config.getProperty("relationModifier." + type); if (attr == null) - throw new UnknownRelationModifierException(mods[i]); + throw new UnknownRelationModifierException(type); attrs.add(attr); } -- 1.7.10.4