51 NWBFile(std::shared_ptr<IO::BaseIO> io);
56 NWBFile(
const std::string& path, std::shared_ptr<IO::BaseIO> io);
88 const std::string& description =
"a recording session",
89 const std::string& dataCollection =
"",
90 const std::string& sessionStartTime =
"",
91 const std::string& timestampsReferenceTime =
"");
118 std::vector<Types::ChannelVector> recordingArrays,
119 bool finalizeTable =
true);
138 std::vector<Types::ChannelVector> recordingArrays,
139 std::vector<std::string> recordingNames,
141 std::vector<SizeType>& containerIndexes);
157 std::vector<Types::ChannelVector> recordingArrays,
158 std::vector<std::string> recordingNames,
160 std::vector<SizeType>& containerIndexes);
171 std::vector<SizeType>& containerIndexes);
176 "table with the extracellular electrodes")
187 A record of the date the file was created and of
188 subsequent modifications)
194 A unique text identifier for the file)
199 "session_description",
200 A description of the experimental session and data in the
206 "session_start_time",
207 Date and time of the experiment or session start)
212 "timestamps_reference_time",
213 Date and time corresponding to time zero of all
240 const std::
string& description,
241 const std::
string& dataCollection,
242 const std::
string& sessionStartTime,
243 const std::
string& timestampsReferenceTime);
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
#define DEFINE_DATASET_FIELD(readName, writeName, default_type, fieldPath, description)
Defines a lazy-loaded dataset field accessor function.
Definition RegisteredType.hpp:573
#define DEFINE_UNNAMED_REGISTERED_FIELD(readName, writeName, registeredType, fieldPrefixPath, description)
Defines a lazy-loaded accessor function for reading fields that are RegisteredTypes that do not have ...
Definition RegisteredType.hpp:677
#define DEFINE_REGISTERED_FIELD(name, registeredType, fieldPath, description)
Defines a lazy-loaded accessor function for reading fields that are RegisteredTypes.
Definition RegisteredType.hpp:638
Represents a base data type.
Definition BaseIO.hpp:47
Represents a table containing electrode metadata.
Definition ElectrodesTable.hpp:17
static const std::string electrodesTablePath
The path to the ElectrodesTable.
Definition ElectrodesTable.hpp:84
Status initialize()
Initialize the object.
Definition NWBContainer.cpp:17
NWBContainer(const std::string &path, std::shared_ptr< AQNWB::IO::BaseIO > io)
Constructor.
Definition NWBContainer.cpp:11
std::shared_ptr< AQNWB::IO::BaseRecordingData > recordTimestampsReferenceTime(bool reset=false)
Status createSpikeEventSeries(std::vector< Types::ChannelVector > recordingArrays, std::vector< std::string > recordingNames, const IO::BaseDataType &dataType, std::vector< SizeType > &containerIndexes)
Create SpikeEventSeries objects to record data into. Created objects are automatically added to the I...
Definition NWBFile.cpp:297
std::unique_ptr< RTYPE > createAquisitionSeries(std::string &objectName) const
std::shared_ptr< AQNWB::IO::BaseRecordingData > recordFileCreateDate(bool reset=false)
std::shared_ptr< ElectrodesTable > createElectrodesTable(std::vector< Types::ChannelVector > recordingArrays, bool finalizeTable=true)
Create ElectrodesTable. Note, this function will fail if the file is in a mode where new objects cann...
Definition NWBFile.cpp:197
NWBFile(std::shared_ptr< IO::BaseIO > io)
Constructor for NWBFile class.
Definition NWBFile.cpp:35
std::unique_ptr< AQNWB::IO::ReadDataWrapper< AQNWB::NWB::DatasetField, VTYPE > > readTimestampsReferenceTime() const
std::unique_ptr< AQNWB::IO::ReadDataWrapper< AQNWB::NWB::DatasetField, VTYPE > > readSessionDescription() const
NWBFile(const NWBFile &)=delete
Deleted copy constructor to prevent construction-copying.
std::shared_ptr< AQNWB::IO::BaseRecordingData > recordIdentifier(bool reset=false)
std::shared_ptr< RTYPE > readAquisitionSeries(std::string &objectName) const
std::shared_ptr< RTYPE > readElectrodesTable() const
Status createFileStructure(const std::string &identifierText, const std::string &description, const std::string &dataCollection, const std::string &sessionStartTime, const std::string ×tampsReferenceTime)
Creates the default file structure. Note, this function will fail if the file is in a mode where new ...
Definition NWBFile.cpp:140
std::shared_ptr< AQNWB::IO::BaseRecordingData > recordSessionStartTime(bool reset=false)
static std::shared_ptr< NWBFile > create(const std::string &path, std::shared_ptr< AQNWB::IO::BaseIO > io)
NWBFile & operator=(const NWBFile &)=delete
Deleted copy assignment operator to prevent copying.
std::unique_ptr< ElectrodesTable > m_electrodeTable
The ElectrodesTable for the file.
Definition NWBFile.hpp:261
std::unique_ptr< AQNWB::IO::ReadDataWrapper< AQNWB::NWB::DatasetField, VTYPE > > readIdentifier() const
~NWBFile()
Destructor for NWBFile class.
Definition NWBFile.cpp:50
Status createAnnotationSeries(std::vector< std::string > recordingNames, std::vector< SizeType > &containerIndexes)
Create AnnotationSeries objects to record data into. Created objects are automatically added to the I...
Definition NWBFile.cpp:372
void cacheSpecifications(const Types::NamespaceInfo &namespaceInfo)
Saves the specification files for the schema.
Definition NWBFile.cpp:407
bool isInitialized() const
Check if the NWB file is initialized.
Definition NWBFile.cpp:103
std::unique_ptr< AQNWB::IO::ReadDataWrapper< AQNWB::NWB::AttributeField, VTYPE > > readNWBVersion() const
std::unique_ptr< AQNWB::IO::ReadDataWrapper< AQNWB::NWB::DatasetField, VTYPE > > readFileCreateDate() const
Status createElectricalSeries(std::vector< Types::ChannelVector > recordingArrays, std::vector< std::string > recordingNames, const IO::BaseDataType &dataType, std::vector< SizeType > &containerIndexes)
Create ElectricalSeries objects to record data into. Created objects are automatically added to the I...
Definition NWBFile.cpp:239
static const std::string m_acquisitionPath
Definition NWBFile.hpp:254
std::unique_ptr< AQNWB::IO::ReadDataWrapper< AQNWB::NWB::DatasetField, VTYPE > > readSessionStartTime() const
std::shared_ptr< AQNWB::IO::BaseRecordingData > recordSessionDescription(bool reset=false)
static const std::string m_specificationsPath
Definition NWBFile.hpp:256
static std::shared_ptr< RegisteredType > create(const std::string &fullClassName, const std::string &path, std::shared_ptr< IO::BaseIO > io, bool fallbackToBase=false)
Create an instance of a registered subclass by name.
Definition RegisteredType.cpp:75
General purpose time series.
Definition TimeSeries.hpp:18
Provides definitions for various types used in the project.
Definition Types.hpp:17
The namespace for IO components of AqNWB.
Namespace for all classes related to the NWB data standard.
const std::string namespaceName
Definition core.hpp:21