| 227 | } |
| 228 | |
| 229 | void TileDBReader::addDimensions(PointLayoutPtr layout) |
| 230 | { |
| 231 | for (const auto& dim : m_array->schema().domain().dimensions()) |
| 232 | addDim(layout, dim.name(), dim.type(), true); |
| 233 | |
| 234 | for (const auto& [attrName, attr] : m_array->schema().attributes()) |
| 235 | { |
| 236 | // Check for special packed bit-field dimension. |
| 237 | if (attrName == "BitFields") |
| 238 | { |
| 239 | if (attr.type() != TILEDB_UINT16) |
| 240 | { |
| 241 | if (m_args->m_strict) |
| 242 | throwError("Cannot add type '" + attrName + |
| 243 | "'. Unexpected type not equal to uint16_t."); |
| 244 | else |
| 245 | std::cerr << "Skipping over attribute '" << attrName |
| 246 | << "' with unexpected type!\n"; |
| 247 | } |
| 248 | m_dims.emplace_back(new BitFieldsBuffer(attrName, layout)); |
| 249 | } |
| 250 | else |
| 251 | addDim(layout, attrName, attr.type(), m_args->m_strict); |
| 252 | } |
| 253 | } |
| 254 | |
| 255 | void TileDBReader::ready(PointTableRef) |
| 256 | { |