return PyBool_FromLong(headerIsEntry(s->h, tag));
}
+static PyObject *hdrConvert(hdrObject *self, PyObject *args, PyObject *kwds)
+{
+ char *kwlist[] = {"op", NULL};
+ headerConvOps op = -1;
+
+ if (!PyArg_ParseTupleAndKeywords(args, kwds, "i", kwlist, &op)) {
+ return NULL;
+ }
+ return PyBool_FromLong(headerConvert(self->h, op));
+}
+
static int hdr_compare(hdrObject * a, hdrObject * b)
{
return rpmVersionCompare(a->h, b->h);
NULL },
{"fullFilelist", (PyCFunction) hdrFullFilelist, METH_NOARGS,
NULL },
+ {"convert", (PyCFunction) hdrConvert, METH_VARARGS|METH_KEYWORDS,
+ NULL },
{"has_key", (PyCFunction) hdrHasKey, METH_O,
NULL },
{"sprintf", (PyCFunction) hdrSprintf, METH_VARARGS|METH_KEYWORDS,
REGISTER_ENUM(TR_REMOVED);
REGISTER_ENUM(RPMDBI_PACKAGES);
+
+ REGISTER_ENUM(HEADERCONV_EXPANDFILELIST);
+ REGISTER_ENUM(HEADERCONV_COMPRESSFILELIST);
+ REGISTER_ENUM(HEADERCONV_RETROFIT_V3);
}