OdkForm¶
ODKInstance ¶
ODKInstance(filespec=None, data=None)
Bases: object
Parameters:
Name | Type | Description | Default |
---|---|---|---|
filespec
|
str
|
The filespec to the ODK XML Instance file |
None
|
data
|
str
|
The XML data |
None
|
Returns:
Type | Description |
---|---|
ODKInstance
|
An instance of this object |
Source code in osm_fieldwork/ODKInstance.py
35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 |
|
parse ¶
parse(filespec, data=None)
Import an ODK XML Instance file ito a data structure. The input is either a filespec to the Instance file copied off your phone, or the XML that has been read in elsewhere.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
filespec
|
str
|
The filespec to the ODK XML Instance file |
required |
data
|
str
|
The XML data |
None
|
Returns:
Type | Description |
---|---|
dict
|
All the entries in the OSM XML Instance file |
Source code in osm_fieldwork/ODKInstance.py
58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 |
|