summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
...
* Replaced all 'for' iterations on xmlNodes with 'foreach_xmlnode'David Sommerseth2009-06-021-9/+9
|
* Removed no longer needed function - is_int()David Sommerseth2009-06-022-10/+0
| | | | | This function did not work as expected and due to the rewrite of xmlpythonizer, this function is not longer needed.
* Rewrote the dmiMAP_ParseMappingXML(...) function and split it upDavid Sommerseth2009-06-022-78/+124
| | | | | | | | | | | | | | | | Removed the automagic in the dmiMAP_ParseMappingXML(...) function from automatically decide what to parse (TypeMapping or GroupMapping). Introduced two new functions instead: - dmiMAP_ParseMappingXML_GroupName(xmlDoc *xmlmap, const char *name) Parses the XML mapping document, using the GroupMapping tags and building up a proper ptzMAP structure for all TypeMap defined in that group. - dmiMAP_ParseMappingXML_TypeID(xmlDoc *xmlmap, const char *typeid) Parses the XML mapping document, using only the TypeMapping section in th mapping document. Rewrote a lot of internal parts to reuse as much of the existing code as possible.
* Rewrote dmixml_FindNodeByAttr(...) function to also use TagNameDavid Sommerseth2009-06-022-21/+19
| | | | The previous version did not consider the tag name when searching for nodes.
* Added a simple helper macro to simplify xmlNode traversingDavid Sommerseth2009-05-291-0/+2
|
* Removed unneeded section (already commented out)David Sommerseth2009-05-271-5/+1
|
* Fixed WIP from last night (with notes)Nima Talebi2009-05-271-12/+16
| | | | | | | | | | Note that this will not work as expected for `group mappings' that have unimplemented `type maps', and this is because the linked-list chain will ne broken at the first unimplemented `type map' There is no reason to code a workaround for this as the type do have to be implemented eventually, and hence added code will merely be noise.
* WIP commitNima Talebi2009-05-2710-580/+563
| | | | | | | | Merged the two XML files into one, and amended relevant code. I still want to modify the XML tag names, but not yet. The calls to dmidecode.type() not function as expected, but the others are broken - this is next.
* Small update, added FIXME tags and commentsNima Talebi2009-05-241-28/+31
|
* Added placeholder for most `type'sNima Talebi2009-05-241-147/+258
| | | | In doing so, found and fixed a few mistakes in my previous commit.
* Follow-up on recent XML config file renameNima Talebi2009-05-243-4/+4
|
* Renamed XML config files to better match codeNima Talebi2009-05-242-0/+0
|
* Update header file for new function declarationNima Talebi2009-05-241-1/+1
|
* AutoheaderedNima Talebi2009-05-241-42/+113
|
* Return earlier when possibleNima Talebi2009-05-241-4/+4
|
* Loading in the new the new `type' XML fileNima Talebi2009-05-242-2/+13
|
* Broken commit - change in XML mapping designNima Talebi2009-05-243-312/+358
| | | | | | | | | | | Rather than hardcoding the data by function name (e.g. system, bios, connector, slot, etc), create each `type' as an individual XML tree, then group them under user-friendly names (as per the function names). Here the `pythonmap.xml' groups (but does not define) the various types (0..255), the types themselves are however defined in `typemap.xml'. This commit is broken, and a WIP.
* Completed preliminary reimplementation of type()Nima Talebi2009-05-246-20/+69
| | | | | | | Updated test unit to match. Throw an exception instead of returning None/False in some functions.
* Reimplementing the type() function - WIPNima Talebi2009-05-234-6/+29
|
* Reimplementing support for the type() method - WIPNima Talebi2009-05-231-0/+21
|
* Completed test caseNima Talebi2009-05-232-3/+3
| | | | | | | Removed trailing spaces from xml data file. Commented out fprintf()s for now (Perhapse should add them to the debug build at least).
* More cleanupNima Talebi2009-05-235-7/+12
| | | | | | | | | Don't write to stdout unless in debug mode (with respect to writing to memory devices. Added the xml datafile to setup (distutils). Updated test case (incorporating color and cleaning up tests).
* Updating Debian-specificsNima Talebi2009-05-232-3/+5
|
* Final cleanupNima Talebi2009-05-231-1/+1
|
* Fixed minor bug which prevented debug buildsNima Talebi2009-05-232-2/+4
|
* Reversioned, relicensed, and rejiggedNima Talebi2009-05-225-46/+85
| | | | | | | | | | | The version is of now, v3.10.6. The version major field has been upped due to the newly added XML functionality. The version has been reverted to GPLv2. Some headers have been cleaned up, copyright notices added etc. Credits given where due.
* Update copyright noticeNima Talebi2009-05-222-6/+14
|
* Bringing setup files upto dateNima Talebi2009-05-222-9/+12
|
* Fixed a bug, and preparing to dupload to DebianNima Talebi2009-05-221-1/+1
|
* Changed the node content of /dmidecode/ProcessorInfo/CPUCore/cpu_flags/flag ↵David Sommerseth2009-05-201-30/+30
| | | | | | | to maintain backwards compatibility The old python-dmidecode uses the format '{flag} ({description})'. This format is now used is well as contents for the cpu_flags/flag text nodes.
* Fixed the bios field mapping to use relative XPathsDavid Sommerseth2009-05-201-23/+23
|
* Added field mapping for dmidecode.connectors()David Sommerseth2009-05-201-0/+22
|
* Added field mapping for dmidecode.slots()David Sommerseth2009-05-201-0/+22
|
* Use correct index value for ↵David Sommerseth2009-05-201-1/+1
| | | | /dmidecode/SystemSlots/SlotCharacteristics/Characteristic/@index
* Added field mapping for dmidecode.baseboard()David Sommerseth2009-05-201-0/+28
|
* Added field mapping for the dmidecode.system() sectionDavid Sommerseth2009-05-201-3/+52
|
* Added support for value type 'list:dict' for field mappingDavid Sommerseth2009-05-202-14/+80
| | | | | | | | | | | | | | This builds up a list of dicts. Syntax is: <Map keytype="constant" key="TestData" valuetype="list:dict" value="/xml/XPath/to/nodes"> <Map keytype="constant" key="field" valuetype="string" key="ValueNode"/> </Map> The parser will iterate all nodes defined in the @value attribute and the root path will of the nested mapping will be using the path in @value as the root path for further parsing.
* Added field python dict mapping for CacheInfoDavid Sommerseth2009-05-201-0/+36
|
* Fixed some errors in the XML layout on CacheInfoDavid Sommerseth2009-05-201-3/+3
|
* Added a few missing commentsDavid Sommerseth2009-05-201-0/+8
|
* Fixed some ugly, unattractive and unhealthy codeNima Talebi2009-05-201-12/+0
| | | | | These hangover lines must have crept in at the early stages of the initial conversion of dmidecode to python-dmidecode. Fixed.
* Reorganised attributes in SystemSlots tagDavid Sommerseth2009-05-151-6/+43
| | | | | | This part of the XML result was not valid due to duplicated tag attributes. Moved some of this specifications from the SystemSlots tag to its own SlotID tag, with even more details.
* Completed mapping the memory sectionDavid Sommerseth2009-05-151-0/+46
|
* Fixed some errors in decoding "3.3.5.9 Processor Characteristics"David Sommerseth2009-05-151-2/+1
| | | | Fixes regression in parsing introduced when rewriting dmidecode to use libxml2
* Added 'emptyValue' attribute in the Map tagDavid Sommerseth2009-05-152-16/+34
| | | | | This attribute defines a default value when XML source data is empty
* Remove 'ns' from the speed_ns attribute in memory sectionDavid Sommerseth2009-05-141-1/+1
|
* Added new Map attribute - emptyIsNoneDavid Sommerseth2009-05-142-14/+59
| | | | | | | | If the emptyIsNone attribute is set to "1", the Python result will be forced to Py_None if the referenced XML value is empty. When checking if the value is empty, the XML value is right trimmed to remove trailing spaces. Only spaces are are removed.
* Support fixed size listsDavid Sommerseth2009-05-142-3/+69
| | | | | | | | | When using one of the list types as valuetype, the Map tag now also supports fixedsize and index_attr attributes. - fixedsize : Defines a fixed size of the list - index_attr : Defines an attribute name of the input XML data which contains the list index for the value
* Fixed another parser issueDavid Sommerseth2009-05-141-111/+122
| | | | | When using rootpath, it did not parse all elements as expected. Also restricted the rootpath to only work when valuetype="dict".
* Avoid segfault if XPATH_NODESET do not contain any dataDavid Sommerseth2009-05-131-1/+6
|