X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=ovsdb%2Fovsdb-idlc.in;h=6c8aa435cf59280f1c833d245c451fa43b0e64aa;hb=HEAD;hp=d680f7c6cd86d409b7a04e7c4d77bff4854ed03c;hpb=3ba9c6a5a5468626dcfeb1f9a750bb0efc8c6a7a;p=sliver-openvswitch.git diff --git a/ovsdb/ovsdb-idlc.in b/ovsdb/ovsdb-idlc.in index d680f7c6c..6c8aa435c 100755 --- a/ovsdb/ovsdb-idlc.in +++ b/ovsdb/ovsdb-idlc.in @@ -110,6 +110,7 @@ def printCIDLHeader(schemaFile): print "\nextern struct ovsdb_idl_column %s_columns[%s_N_COLUMNS];" % (structName, structName.upper()) print ''' +const struct %(s)s *%(s)s_get_for_uuid(const struct ovsdb_idl *, const struct uuid *); const struct %(s)s *%(s)s_first(const struct ovsdb_idl *); const struct %(s)s *%(s)s_next(const struct %(s)s *); #define %(S)s_FOR_EACH(ROW, IDL) \\ @@ -381,6 +382,12 @@ void # First, next functions. print ''' +const struct %(s)s * +%(s)s_get_for_uuid(const struct ovsdb_idl *idl, const struct uuid *uuid) +{ + return %(s)s_cast(ovsdb_idl_get_row_for_uuid(idl, &%(p)stable_classes[%(P)sTABLE_%(T)s], uuid)); +} + const struct %(s)s * %(s)s_first(const struct ovsdb_idl *idl) {