Code Duplication    Length = 9-9 lines in 2 locations

lib/Doctrine/ODM/CouchDB/Mapping/Driver/XmlDriver.php 2 locations

@@ 93-101 (lines=9) @@
90
91
        // Evaluate <field ...> mappings
92
        if (isset($xmlRoot->field)) {
93
            foreach ($xmlRoot->field as $fieldMapping) {
94
                $class->mapField(array(
95
                    'fieldName' => (string)$fieldMapping['name'],
96
                    'jsonName'  => (isset($fieldMapping['json-name'])) ? (string)$fieldMapping['json-name'] : null,
97
                    'indexed'   => (isset($fieldMapping['index'])) ? (bool)$fieldMapping['index'] : false,
98
                    'type'      => (isset($fieldMapping['type'])) ? (string)$fieldMapping['type'] : null,
99
                    'isVersionField'   => (isset($fieldMapping['version'])) ? true : null,
100
                ));
101
            }
102
        }
103
104
        // Evaluate <id ..> mappings
@@ 105-113 (lines=9) @@
102
        }
103
104
        // Evaluate <id ..> mappings
105
        foreach ($xmlRoot->id as $idElement) {
106
            $class->mapField(array(
107
                'fieldName' => (string)$idElement['name'],
108
                'indexed'   => (isset($idElement['index'])) ? (bool)$idElement['index'] : false,
109
                'type'      => (isset($idElement['type'])) ? (string)$idElement['type'] : null,
110
                'id'        => true,
111
                'strategy'  => (isset($idElement['strategy'])) ? (string)$idElement['strategy'] : null,
112
            ));
113
        }
114
115
        // Evaluate <version ..> mappings
116
        foreach ($xmlRoot->version as $versionElement) {