From 884c8a4ebdfcedf8143dcb2ce8ef92779c353e06 Mon Sep 17 00:00:00 2001 From: Julian Andres Klode Date: Thu, 4 Jun 2009 17:18:29 +0200 Subject: python/: Unify naming conventions for all new names. Unify all names to follow these rules: 1. Replace the first [A-Z] with the lowercase version [a-z] 2. Replace multiple [A-Z] with [A-Z][a-z] (one upper, remaining ones lowercase) 3. Replace all remaining [A-Z] with _[a-z] This brings us from 'FileName' to 'file_name' and from 'DescURI' to 'desc_uri'. We will at a later stage add some exceptions to this rule, like 'filename' instead of 'file_name', to improve readability. --- python/pkgrecords.cc | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'python/pkgrecords.cc') diff --git a/python/pkgrecords.cc b/python/pkgrecords.cc index f9e48352..48440387 100644 --- a/python/pkgrecords.cc +++ b/python/pkgrecords.cc @@ -120,18 +120,18 @@ static PyObject *PkgRecordsGetRecord(PyObject *Self,void*) { return PyString_FromStringAndSize(start,stop-start); } static PyGetSetDef PkgRecordsGetSet[] = { - {"filename",PkgRecordsGetFileName}, + {"file_name",PkgRecordsGetFileName}, {"homepage",PkgRecordsGetHomepage}, - {"longdesc",PkgRecordsGetLongDesc}, - {"md5",PkgRecordsGetMD5Hash}, + {"long_desc",PkgRecordsGetLongDesc}, + {"md5_hash",PkgRecordsGetMD5Hash}, {"maintainer",PkgRecordsGetMaintainer}, {"name",PkgRecordsGetName}, {"record",PkgRecordsGetRecord}, - {"sha1",PkgRecordsGetSHA1Hash}, - {"sha256",PkgRecordsGetSHA256Hash}, - {"shortdesc",PkgRecordsGetShortDesc}, - {"sourcepkg",PkgRecordsGetSourcePkg}, - {"sourcever",PkgRecordsGetSourceVer}, + {"sha1_hash",PkgRecordsGetSHA1Hash}, + {"sha256_hash",PkgRecordsGetSHA256Hash}, + {"short_desc",PkgRecordsGetShortDesc}, + {"source_pkg",PkgRecordsGetSourcePkg}, + {"source_ver",PkgRecordsGetSourceVer}, #ifdef COMPAT_0_7 {"FileName",PkgRecordsGetFileName}, {"Homepage",PkgRecordsGetHomepage}, -- cgit v1.2.3