rename expitem to invitem a it's an inventory query
diff --git a/reclass/values/expitem.py b/reclass/values/invitem.py
similarity index 97%
rename from reclass/values/expitem.py
rename to reclass/values/invitem.py
index c947da1..2470e5f 100644
--- a/reclass/values/expitem.py
+++ b/reclass/values/invitem.py
@@ -20,7 +20,7 @@
_EQUAL = '=='
_NOT_EQUAL = '!='
-class ExpItem(Item):
+class InvItem(Item):
def _get_parser():
@@ -74,7 +74,7 @@
_parser = _get_parser()
def __init__(self, item, delimiter):
- self.type = Item.EXPORT
+ self.type = Item.INV_QUERY
self._delimiter = delimiter
self._expr_type = None
self._refs = []
@@ -83,7 +83,7 @@
def _parse_expression(self, expr):
try:
- tokens = ExpItem._parser.parseString(expr).asList()
+ tokens = InvItem._parser.parseString(expr).asList()
except pp.ParseException as e:
raise ParseError(e.msg, e.line, e.col, e.lineno)
@@ -192,4 +192,4 @@
return ' '.join(str(j) for i,j in self._expr)
def __repr__(self):
- return 'ExpItem(%r)' % self._expr
+ return 'InvItem(%r)' % self._expr
diff --git a/reclass/values/item.py b/reclass/values/item.py
index 19d1d34..75f5eb6 100644
--- a/reclass/values/item.py
+++ b/reclass/values/item.py
@@ -11,7 +11,7 @@
COMPOSITE = 1
DICTIONARY = 2
- EXPORT = 3
+ INV_QUERY = 3
LIST = 4
REFERENCE = 5
SCALAR = 6
diff --git a/reclass/values/parser.py b/reclass/values/parser.py
index d32bfde..35bb355 100644
--- a/reclass/values/parser.py
+++ b/reclass/values/parser.py
@@ -7,7 +7,7 @@
import pyparsing as pp
from compitem import CompItem
-from expitem import ExpItem
+from invitem import InvItem
from refitem import RefItem
from scaitem import ScaItem
@@ -158,6 +158,6 @@
for token in tokens:
items.append(ScaItem(token[1]))
if len(items) == 1:
- return ExpItem(items[0], self._delimiter)
+ return InvItem(items[0], self._delimiter)
else:
- return ExpItem(CompItem(items), self._delimiter)
+ return InvItem(CompItem(items), self._delimiter)