aqnwb 0.2.0
Loading...
Searching...
No Matches
Device.hpp
Go to the documentation of this file.
1#pragma once
2
3#include <string>
4
5#include "Utils.hpp"
6#include "io/BaseIO.hpp"
7#include "io/ReadIO.hpp"
9#include "spec/core.hpp"
10
11namespace AQNWB::NWB
12{
17class Device : public NWBContainer
18{
19public:
20 // Register the Device as a subclass of NWBContainer
22
23 // Bring base class initialize method into scope
25
26protected:
32 Device(const std::string& path, std::shared_ptr<IO::BaseIO> io);
33
34public:
38 ~Device();
39
48 Status initialize(const std::string& description,
49 const std::string& manufacturer);
50
51 // Define the data fields to expose for lazy read access
53 std::string,
54 "description",
55 Description of the series)
56
58 std::string,
59 "manufacturer",
60 Manufacturer of the device)
61};
62} // namespace AQNWB::NWB
AQNWB::Types::Status Status
Definition BaseIO.hpp:22
#define REGISTER_SUBCLASS(T, BASE, NAMESPACE)
Macro to register a subclass with the RegisteredType class registry.
Definition RegisteredType.hpp:501
#define DEFINE_ATTRIBUTE_FIELD(name, default_type, fieldPath, description)
Defines a lazy-loaded attribute field accessor function.
Definition RegisteredType.hpp:534
Status initialize()
Initialize the container.
Definition Container.cpp:20
Device(const std::string &path, std::shared_ptr< IO::BaseIO > io)
Constructor.
Definition Device.cpp:10
Status initialize()
Initialize the container.
Definition Container.cpp:20
std::unique_ptr< AQNWB::IO::ReadDataWrapper< AQNWB::NWB::AttributeField, VTYPE > > readManufacturer() const
~Device()
Destructor.
Definition Device.cpp:16
std::unique_ptr< AQNWB::IO::ReadDataWrapper< AQNWB::NWB::AttributeField, VTYPE > > readDescription() const
NWBContainer(const std::string &path, std::shared_ptr< AQNWB::IO::BaseIO > io)
Constructor.
Definition NWBContainer.cpp:11
Namespace for all classes related to the NWB data standard.
const std::string namespaceName
Definition core.hpp:21