/// @} /// @class Bds::AdminAccess /// @details To use this BdsServer access object you would create one like "DataAccess bds;". /// Then you would connect it to a particular BdsServer running on a particular host using the connectService(in String) function. /// Once connected you need to login to the BdsServer as a particular user using the connect(in String user, in String password). /// After your have successfully logged in you can use the various objects methods. These result in a remote procedure call (RPC) to the BdsServer which /// Will imlement the function and return any data and normally an errors status (BError). /// @fn Bds::AdminAccess::AdminAccess /// @brief BDS RPC access class. /// @param name The URL of the remote BOAP object name to connect to. /// @details This object constructor takes the name of the remote object to connect to. However this is normally passed as "" as the connectService() function is normally used to perform the actual remote connection. /// @fn BError Bds::AdminAccess::validateUser /// @param user The user's name /// @param email The users email address /// @details Checks to see if the user as named exsists or if just the email address is provided, if any user with that email address exists. /// @fn BError Bds::AdminAccess::setUser /// @param user The user's name /// @param email The users email address /// @details Changes the connection to be logged in as the given user by their user name or email address. /// This function will only be allowed if the current user is in the userSet group. The bdsAutodrm user normally has this set so it can change /// the BdsServer's connection to be that of the BdsAutodrm user for example. /// @fn BError Bds::AdminAccess::userGetList /// @param users The returned list of all users /// @details This returns the complete list of users on the system /// @fn BError Bds::AdminAccess::getSelectionInfo /// @param group The type of selection info requested. Can be SelectionGroupData to get selections for Sensor data, /// SelectionGroupMetaData for Metadata selectrions and SelectionGroupDataWithCount as for SelectionGroupData but alos returns the total number of DataChannels. /// @param selectionIn The current selection /// @param selectionInfo The returned selection information /// @details Used for selection systems such as that within a Gui to restrict the options available given partial selection parameters. /// Given a basic Selection returns all of the Selection options available based on the Sensor data or Metadata in the BDS. /// For example if the selectionIn defines one particular Network and one particular Station, the getSelectionInfo function will return a list of Channels /// and Sources for that base selection. /// @fn BError Bds::AdminAccess::getSelections /// @param group The type of selection info requested. Currently ignored. /// @param selectionIn The selection which may include regular expressions and Station arrays. /// @param selectionOut The full Sensor data selection after regular expressions have been expanded and any Array's exapanded into a list of Stations. /// @details This is used to expand a Sensor data Selection to a full Selection list. /// @fn BError Bds::AdminAccess::stationGetList /// @param sel The Selection /// @param stations The list of Stations matching the Selection. /// @details This uses the Network:Station parts of the Selection object to return a list of matching Stations. /// @fn BError Bds::AdminAccess::locationGetList /// @param sel The Selection /// @param locations The list of Locations matching the Selection. /// @details This uses the Network:Station and optionaly the Channel parts of the Selection object to return a list of matching Stations. /// The Selection.locationSelect parameter can be set to LocationSelectAll, LocationSelectStation or LocationSelectChannel. /// If set to LocationSelectStation will return the locations of the Stations matched. /// If set to LocationSelectChannel will return the locations of the Channels matched. /// If set to LocationSelectAll (The default) will return the locations of the Channels matched if they have Locations or otherwise that of the Stations. /// @fn BError Bds::AdminAccess::channelGetList /// @param sel The Selection /// @param channels The list of Channels matching the Selection. /// @details If the selection.channelId is set to a value other than 0, this will return a list of one Channel which matches that id. /// Otherwise it will return a list of Channels matchin the Network:Station:Channel regular expression fields of the selection. /// @fn BError Bds::AdminAccess::channelInstrumentGetList /// @param sel The Selection /// @param channelInstruments The list of ChannelInstruments matching the Selection. /// @details This uses the Network:Station:Channel:Source fields of the Selection to return a list of matching Channel Instruments. /// @fn BError Bds::AdminAccess::digitiserGetList /// @param sel The Selection /// @param digitisers The list of Digitisers matching the Selection. /// @details If selection.digitiserId is set, then return the single matching Digitiser. Otherwise use the Selection's Network:Station:Channel:Source fields to return a list of matching Digitisers. /// @fn BError Bds::AdminAccess::sensorGetList /// @param sel The Selection /// @param sensors The list of Sensors matching the Selection. /// @details If selection.sensorId is set, then return the single matching Sensor. Otherwise use the Selection's Network:Station:Channel:Source fields to return a list of matching Sensors. /// @fn BError Bds::AdminAccess::responseGetList /// @param sel The Selection /// @param responses The list of Responses matching the Selection. /// @details Use the Selection's Network:Station:Channel:Source fields to return a list of matching Responses. /// @fn BError Bds::AdminAccess::eventGetList /// @param sel The Selection /// @param events The list of Events matching the Selection. /// @details If sel.id or sel.eventId is set then return the Event with this ID. /// Otherwise if sel.name is set return an Event with a title matching this regular expression between sel.startTime and sel.endTime.. /// Otherwise match any events between sel.startTime and sel.endTime. /// @fn BError Bds::AdminAccess::specialChannelGetList /// @param sel The Selection /// @param specialChannels The list of SpecialChannels matching the Selection. /// @details This will return a list of SpecialChannels matchin the Network:Station:Channel regular expression fields of the selection. /// @fn BError Bds::AdminAccess::metadataGetChannelInfo /// @param sel Channels selection /// @param channelInfos Metadata information for the channels /// @details This function is designed to help when exporting data from the BDS. It will attempt to gather all of the Metadata present for the Channels selected. /// Depending on the dataType of the selected Channels it will check that the expected Metadata is present and if not return an Error. /// For Channels of dataType "seismic" it will check that the following Metadata information exists: Station, Channel, Location. Calibration, Response, ChannelInstrument. /// For each of the selected Channels there will be an array of ChannelInfo objects. The BdsServer will segment the Metadata in time periods at each point an of this Metadata is changed. /// This each ChannelInfo object will return a set of Metadata over a time period that has no change in Metadata. When exporting data it can be time segmented to /// match this. /// @fn BError Bds::AdminAccess::metadataGetFormatted /// @param sel Channels selection /// @param format The requested Metadata output format. This should match a format specified by any of the BDS data convertors. /// @param data The raw file data for the format given in bytes. /// @details This function gathers all of the Metadata for the channels matching the Selection and then finds a suitable BDS data format conertor to export this Metadata in /// the chosen format. The resultion array of Byte data can be written to a suitable file. /// @fn BError Bds::AdminAccess::dataFileGetList /// @param sel Channels selection /// @param dataFiles The returned DataFiles /// @details If sel.id is set, then returns the single DataFile matching this id. /// Otherwise uses the Selection's Network:Station:Channel:Source fields to select a list of DataFiles. /// @fn BError Bds::AdminAccess::dataChannelGetList /// @param sel Channels selection /// @param dataChannels The returned DataChannel /// @details Uses the Selection's Network:Station:Channel:Source fields to select a list of DataChannels. /// @fn BError Bds::AdminAccess::dataAvailability /// @param sel The selection information /// @param num The number of availability time segments to return. /// @param dataAvailChans Information on the availablility of sensor data for the selected channel /// @details This function will return a list of Sensor data availability information for the selected Channels. /// If num > 0 then it will restrict the number of time segments to that number. The time segments will be linearly spaced in time. /// If num ==0 then the system will return a data availabliliy segment for each DataChannel continuous segment. This can be slow and return a very large number of segments. /// @fn BError Bds::AdminAccess::dataSearch /// @param selection Channel Selection information /// @param dataInfo Sensor data selection information with data segmented by actual data file segments with extra information if available /// @details This will perform a search for Sensor data matching the Selection. Be careful with the selction as their could be a lot of data matching /// that will then hit resource limits. There are restrictions on the maximum time range allowed (MaxTimePeriod) and the maximum DataChannel segments returned (MaxNumChannels). /// The return DataInfo object can be interidated for information on the data, such as sampleRates and/or used in the dataOpen() function /// for actual access to the Sensor data. /// @fn BError Bds::AdminAccess::dataGetChannelInfo /// @param dataInfo Data selection /// @param channelInfos Metadata information for the channels /// @details This function returns all of the Metadata for the given Channels specified in the dataInfo selection. It uses the metadataGetChannelInfo() function /// converting the DataInfo selection to a more general Selection first. /// @fn BError Bds::AdminAccess::dataOpen /// @param dataInfo Data selection defining the Sensor data Channels /// @param mode The open mode. This can be "r" for read access, "w" for write access and "aday" to append to a day file. /// @param format This is the format to use. It can be "API-SM" for multiplexed by sample or "API-CM" for multiplexed by channel. For reads it can also be one of the BDS data convertors supported formats. /// @param flags Bit set of DataFlags. Can include: DataFlagClipDataToTime, DataFlagClipDataToChannels, DataFlagMergeSegments and DataFlagNoMetadata /// @param dataHandle The returned data handle to access this data set /// @details This function opens a set of Sensor data files in the BdsServer for read, write or append access. /// When the format is "API-SM" or "API-CM" then the raw data blocks can be accessed using the dataSeekBlock() and dataGetBlock() functions. Note /// that the "API-SM" format requires the Channels selected to be synchonously sampled and so can only be used for certain import/export data formats where this is the case. /// The flags are used when reading data. Normaly whole contigous DataBlocks are returned. The actual starttime and endtime of the overall data may thus be before and after the selection. /// The DataFlagClipDataToTime "clips" the first and last blocks, removing samples, so the time match the actual selection. /// The DataFlagClipDataToChannels "clips" the blocks so that all of the Channels contain data over the selection period as some Channels otherwise could be missing /// data for a portion of the Selection. /// DataFlagMergeSegments mergese data segments that have matching end and start times into one continuous segment. /// DataFlagNoMetadata ignores Metadata when exporting data. /// @fn BError Bds::AdminAccess::dataGetInfo /// @param dataHandle The opened data set's handle /// @param infoExtra A boolean flag to say to include the extra Metadata containwed within the files /// @param dataInfo The resulting fully filled out DataInfo describing the data. /// @details This functions returns fuller, more detailed, information on the Sensor data using Metadata stored within the data files themselves. /// The BDS data format files can store an extensive amount of Metadata from the various import formats supported. A fair amount of this Metadata is /// freeform and this is for general information purposes only. /// The returned sampleRate is the samplerate calculated on the actual data samples taking into account start and end times as well as actual numbers of continuous samples. /// The DataInfo returned has a set of time segmented information per Channel. Each of the DataInfo segments defines a cotigous set of data with no time discontinuities. /// @fn BError Bds::AdminAccess::dataGetNotes /// @param dataHandle The opened data set's handle /// @param notes A list of Notes on the data /// @details Returns a list of system and user added notes for the data from the database. /// @fn BError Bds::AdminAccess::dataGetWarnings /// @param dataHandle The opened data set's handle /// @param warnings A list of warning strings from the datafiles /// @details Returns a list of warning strings contained within the data files, typically from the data file import convertors. /// @fn BError Bds::AdminAccess::dataSeekBlock /// @param dataHandle The opened data set's handle /// @param channel The channel number. 0 for all channels. /// @param segment The segment number. 0 for all segments /// @param time The time of a sample to search for /// @param blockNumber The returned block number /// @details This seeks for the a DataBlock in the set of files that contains a sample for the time provided. /// If channel is other than 0 then it seeks for a DataBlock for the given channel. If the data is sample multiplexed a Channel number of 0 can be given /// which will return the location of a dataBlock containing all of the Channels. /// If Segment is 0 then the block number returned is referenced to the start of the set of files. If a particular segment number is given then /// the seek and the returned block number is within that segment. /// @fn BError Bds::AdminAccess::dataGetBlock /// @param dataHandle The opened data set's handle /// @param channel The channel number. 0 for all channels. /// @param segment The segment number. 0 for all segments /// @param blockNumber The block number to fetch /// @param dataBlock The returned data block /// @details This returns the given block number from the set of opened data files. /// If channel is other than 0 then it will return the data for the given channel number. If the data is sample multiplexed a Channel number of 0 can be given /// which will return a DataBlock with Sensor data for all of the channels. /// If Segment is 0 then the block number is referenced to the start of the set of files. If a particular segment number is given then /// the returned block number is from within that segment. /// @fn BError Bds::AdminAccess::dataFormattedRead /// @param dataHandle The opened data set's handle /// @param number The maximum number of Bytes to read /// @param data The set of data bytes in the requested format /// @details Given a handle to a set of data files opened for read in an external data format supported by the BDS data converters, read the raw formated data bytes from the converted file. /// @fn BError Bds::AdminAccess::dataRealtimeConfig /// @param enable Enable/disable the sending of a real-time data stream /// @param sel The selection of channels to send /// @details This function has yet to be implemented. It is designed to enable or disable the sening of a stream of data from the BdsServer to a data viewing client. /// @fn BError Bds::AdminAccess::dataRealtimeGet /// @param numBlocks How many blocks to return at a time /// @param numBlocksAvailable The number of blocks available in this stream /// @param dataBlocks A list of the DataBlocks /// @details This function has yet to be implemented. It is designed to return a set of real-time DataBlocks from the BdsServer to a data viewing client. /// @fn BError Bds::AdminAccess::noteGetList /// @param sel Channels selection /// @param notes The returned Notes /// @details Uses the Selection's Network:Station:Channel:Source fields to select a list of Notes. /// @fn BError Bds::AdminAccess::logGetList /// @param sel Log selection /// @param logs The returned Log /// @details Uses the LogSelect to select a set of system logs and return these. /// @fn BError Bds::AdminAccess::logAppend /// @param type The log entries type: error, warning, notice, debug or all. /// @param priority The log events priority from 0 to 5 with 5 being the highest priority /// @param subSystem The subsystem the log entry is from /// @param title A title for the log entry /// @param description A more detailed description of the log entry /// @details This allows BDS xclients, perhaps data import clients, to add BDS system log entries. /// @fn BError Bds::AdminAccess::statisticsGet /// @param info A dictionary of BdsServer statistics /// @details This returns runtime statistics from the BdsServer /// @fn BError Bds::AdminAccess::serverConfigurationGet /// @param info A dictionary of BdsServer configuration entries /// @details This returns the list of server configuration parameters. /// @fn BError Bds::AdminAccess::dataFormatGetList /// @param formats A list of all data file formats /// @details This returns the list of all of the data file formats supported by the BdsServer's data convertors. /// @fn BError Bds::AdminAccess::transactionStart /// @details Starts a database transaction. A database transaction allows an atomic update of a set of database parameters with the option to abort the whole change. /// @fn BError Bds::AdminAccess::transactionStart /// @param abort Abort or complete the transaction normally /// @details Completes a database transaction with an option to abort the changes. /// @fn BError Bds::AdminAccess::modeSet /// @param mode The new server mode /// @param previousMode The current server mode returned /// @details Changes the mode of a BdsServer's operation. A BdsServer can be in ModeMaster or ModeSlave modes. /// In ModeSlave it will act as a read only BdsServer which can be used for resiliance, data protection or for peerformance purposes. /// @fn BError Bds::AdminAccess::modeSnapshotPause /// @param on Enabvle/disable pause /// @details Preforms a snapshot pause. When in this mode all changes to the database and data files will be blocked untill the end of the pause. /// This allows a backup to be performed with consistant files. /// @fn BError Bds::AdminAccess::clean /// @param cleanOptions Clean options. This has the options logs, changes and deletedFiles /// @details This function can be used to clean up old data. It should be called once in a while to perform this work. /// It will clean the given items that are over a year old. /// @fn BError Bds::AdminAccess::databaseBackup /// @param ref Reference and file name component /// @details This will perform a complede BDS database backup into a file with the given reference name. /// @fn BError Bds::AdminAccess::databaseRestore /// @param ref Reference and file name component /// @param type The typed of database tables to restore. Can be admin, data, metadata or all /// @details This will perform a restore of the selected sets of database tables /// @fn BError Bds::AdminAccess::sqlQuery /// @param query The SQL query /// @param result A list of the returned strings from the database query /// @details This will perform a raw database SQL query. Use with caution! /// @fn BError Bds::AdminAccess::extraCall /// @param function Integer number of an additional function /// @param args Parameters to the function is string form /// @param result return from the function in string form /// @details This has not been implemented but is there to add new functions to the API prior to a full API update /// @class Bds::DataAddAccess /// @details To use this BdsServer access object you would create one like "DataAccess bds;". /// Then you would connect it to a particular BdsServer running on a particular host using the connectService(in String) function. /// Once connected you need to login to the BdsServer as a particular user using the connect(in String user, in String password). /// After your have successfully logged in you can use the various objects methods. These result in a remote procedure call (RPC) to the BdsServer which /// Will imlement the function and return any data and normally an errors status (BError). /// @fn Bds::DataAddAccess::DataAddAccess /// @brief BDS RPC access class. /// @param name The URL of the remote BOAP object name to connect to. /// @details This object constructor takes the name of the remote object to connect to. However this is normally passed as "" as the connectService() function is normally used to perform the actual remote connection. /// @fn BError Bds::DataAddAccess::validateUser /// @param user The user's name /// @param email The users email address /// @details Checks to see if the user as named exsists or if just the email address is provided, if any user with that email address exists. /// @fn BError Bds::DataAddAccess::setUser /// @param user The user's name /// @param email The users email address /// @details Changes the connection to be logged in as the given user by their user name or email address. /// This function will only be allowed if the current user is in the userSet group. The bdsAutodrm user normally has this set so it can change /// the BdsServer's connection to be that of the BdsAutodrm user for example. /// @fn BError Bds::DataAddAccess::userGetList /// @param users The returned list of all users /// @details This returns the complete list of users on the system /// @fn BError Bds::DataAddAccess::getSelectionInfo /// @param group The type of selection info requested. Can be SelectionGroupData to get selections for Sensor data, /// SelectionGroupMetaData for Metadata selectrions and SelectionGroupDataWithCount as for SelectionGroupData but alos returns the total number of DataChannels. /// @param selectionIn The current selection /// @param selectionInfo The returned selection information /// @details Used for selection systems such as that within a Gui to restrict the options available given partial selection parameters. /// Given a basic Selection returns all of the Selection options available based on the Sensor data or Metadata in the BDS. /// For example if the selectionIn defines one particular Network and one particular Station, the getSelectionInfo function will return a list of Channels /// and Sources for that base selection. /// @fn BError Bds::DataAddAccess::getSelections /// @param group The type of selection info requested. Currently ignored. /// @param selectionIn The selection which may include regular expressions and Station arrays. /// @param selectionOut The full Sensor data selection after regular expressions have been expanded and any Array's exapanded into a list of Stations. /// @details This is used to expand a Sensor data Selection to a full Selection list. /// @fn BError Bds::DataAddAccess::stationGetList /// @param sel The Selection /// @param stations The list of Stations matching the Selection. /// @details This uses the Network:Station parts of the Selection object to return a list of matching Stations. /// @fn BError Bds::DataAddAccess::locationGetList /// @param sel The Selection /// @param locations The list of Locations matching the Selection. /// @details This uses the Network:Station and optionaly the Channel parts of the Selection object to return a list of matching Stations. /// The Selection.locationSelect parameter can be set to LocationSelectAll, LocationSelectStation or LocationSelectChannel. /// If set to LocationSelectStation will return the locations of the Stations matched. /// If set to LocationSelectChannel will return the locations of the Channels matched. /// If set to LocationSelectAll (The default) will return the locations of the Channels matched if they have Locations or otherwise that of the Stations. /// @fn BError Bds::DataAddAccess::channelGetList /// @param sel The Selection /// @param channels The list of Channels matching the Selection. /// @details If the selection.channelId is set to a value other than 0, this will return a list of one Channel which matches that id. /// Otherwise it will return a list of Channels matchin the Network:Station:Channel regular expression fields of the selection. /// @fn BError Bds::DataAddAccess::channelInstrumentGetList /// @param sel The Selection /// @param channelInstruments The list of ChannelInstruments matching the Selection. /// @details This uses the Network:Station:Channel:Source fields of the Selection to return a list of matching Channel Instruments. /// @fn BError Bds::DataAddAccess::digitiserGetList /// @param sel The Selection /// @param digitisers The list of Digitisers matching the Selection. /// @details If selection.digitiserId is set, then return the single matching Digitiser. Otherwise use the Selection's Network:Station:Channel:Source fields to return a list of matching Digitisers. /// @fn BError Bds::DataAddAccess::sensorGetList /// @param sel The Selection /// @param sensors The list of Sensors matching the Selection. /// @details If selection.sensorId is set, then return the single matching Sensor. Otherwise use the Selection's Network:Station:Channel:Source fields to return a list of matching Sensors. /// @fn BError Bds::DataAddAccess::responseGetList /// @param sel The Selection /// @param responses The list of Responses matching the Selection. /// @details Use the Selection's Network:Station:Channel:Source fields to return a list of matching Responses. /// @fn BError Bds::DataAddAccess::eventGetList /// @param sel The Selection /// @param events The list of Events matching the Selection. /// @details If sel.id or sel.eventId is set then return the Event with this ID. /// Otherwise if sel.name is set return an Event with a title matching this regular expression between sel.startTime and sel.endTime.. /// Otherwise match any events between sel.startTime and sel.endTime. /// @fn BError Bds::DataAddAccess::specialChannelGetList /// @param sel The Selection /// @param specialChannels The list of SpecialChannels matching the Selection. /// @details This will return a list of SpecialChannels matchin the Network:Station:Channel regular expression fields of the selection. /// @fn BError Bds::DataAddAccess::metadataGetChannelInfo /// @param sel Channels selection /// @param channelInfos Metadata information for the channels /// @details This function is designed to help when exporting data from the BDS. It will attempt to gather all of the Metadata present for the Channels selected. /// Depending on the dataType of the selected Channels it will check that the expected Metadata is present and if not return an Error. /// For Channels of dataType "seismic" it will check that the following Metadata information exists: Station, Channel, Location. Calibration, Response, ChannelInstrument. /// For each of the selected Channels there will be an array of ChannelInfo objects. The BdsServer will segment the Metadata in time periods at each point an of this Metadata is changed. /// This each ChannelInfo object will return a set of Metadata over a time period that has no change in Metadata. When exporting data it can be time segmented to /// match this. /// @fn BError Bds::DataAddAccess::metadataGetFormatted /// @param sel Channels selection /// @param format The requested Metadata output format. This should match a format specified by any of the BDS data convertors. /// @param data The raw file data for the format given in bytes. /// @details This function gathers all of the Metadata for the channels matching the Selection and then finds a suitable BDS data format conertor to export this Metadata in /// the chosen format. The resultion array of Byte data can be written to a suitable file. /// @fn BError Bds::DataAddAccess::dataFileGetList /// @param sel Channels selection /// @param dataFiles The returned DataFiles /// @details If sel.id is set, then returns the single DataFile matching this id. /// Otherwise uses the Selection's Network:Station:Channel:Source fields to select a list of DataFiles. /// @fn BError Bds::DataAddAccess::dataChannelGetList /// @param sel Channels selection /// @param dataChannels The returned DataChannel /// @details Uses the Selection's Network:Station:Channel:Source fields to select a list of DataChannels. /// @fn BError Bds::DataAddAccess::dataAvailability /// @param sel The selection information /// @param num The number of availability time segments to return. /// @param dataAvailChans Information on the availablility of sensor data for the selected channel /// @details This function will return a list of Sensor data availability information for the selected Channels. /// If num > 0 then it will restrict the number of time segments to that number. The time segments will be linearly spaced in time. /// If num ==0 then the system will return a data availabliliy segment for each DataChannel continuous segment. This can be slow and return a very large number of segments. /// @fn BError Bds::DataAddAccess::dataSearch /// @param selection Channel Selection information /// @param dataInfo Sensor data selection information with data segmented by actual data file segments with extra information if available /// @details This will perform a search for Sensor data matching the Selection. Be careful with the selction as their could be a lot of data matching /// that will then hit resource limits. There are restrictions on the maximum time range allowed (MaxTimePeriod) and the maximum DataChannel segments returned (MaxNumChannels). /// The return DataInfo object can be interidated for information on the data, such as sampleRates and/or used in the dataOpen() function /// for actual access to the Sensor data. /// @fn BError Bds::DataAddAccess::dataGetChannelInfo /// @param dataInfo Data selection /// @param channelInfos Metadata information for the channels /// @details This function returns all of the Metadata for the given Channels specified in the dataInfo selection. It uses the metadataGetChannelInfo() function /// converting the DataInfo selection to a more general Selection first. /// @fn BError Bds::DataAddAccess::dataOpen /// @param dataInfo Data selection defining the Sensor data Channels /// @param mode The open mode. This can be "r" for read access, "w" for write access and "aday" to append to a day file. /// @param format This is the format to use. It can be "API-SM" for multiplexed by sample or "API-CM" for multiplexed by channel. For reads it can also be one of the BDS data convertors supported formats. /// @param flags Bit set of DataFlags. Can include: DataFlagClipDataToTime, DataFlagClipDataToChannels, DataFlagMergeSegments and DataFlagNoMetadata /// @param dataHandle The returned data handle to access this data set /// @details This function opens a set of Sensor data files in the BdsServer for read, write or append access. /// When the format is "API-SM" or "API-CM" then the raw data blocks can be accessed using the dataSeekBlock() and dataGetBlock() functions. Note /// that the "API-SM" format requires the Channels selected to be synchonously sampled and so can only be used for certain import/export data formats where this is the case. /// The flags are used when reading data. Normaly whole contigous DataBlocks are returned. The actual starttime and endtime of the overall data may thus be before and after the selection. /// The DataFlagClipDataToTime "clips" the first and last blocks, removing samples, so the time match the actual selection. /// The DataFlagClipDataToChannels "clips" the blocks so that all of the Channels contain data over the selection period as some Channels otherwise could be missing /// data for a portion of the Selection. /// DataFlagMergeSegments mergese data segments that have matching end and start times into one continuous segment. /// DataFlagNoMetadata ignores Metadata when exporting data. /// @fn BError Bds::DataAddAccess::dataGetInfo /// @param dataHandle The opened data set's handle /// @param infoExtra A boolean flag to say to include the extra Metadata containwed within the files /// @param dataInfo The resulting fully filled out DataInfo describing the data. /// @details This functions returns fuller, more detailed, information on the Sensor data using Metadata stored within the data files themselves. /// The BDS data format files can store an extensive amount of Metadata from the various import formats supported. A fair amount of this Metadata is /// freeform and this is for general information purposes only. /// The returned sampleRate is the samplerate calculated on the actual data samples taking into account start and end times as well as actual numbers of continuous samples. /// The DataInfo returned has a set of time segmented information per Channel. Each of the DataInfo segments defines a cotigous set of data with no time discontinuities. /// @fn BError Bds::DataAddAccess::dataGetNotes /// @param dataHandle The opened data set's handle /// @param notes A list of Notes on the data /// @details Returns a list of system and user added notes for the data from the database. /// @fn BError Bds::DataAddAccess::dataGetWarnings /// @param dataHandle The opened data set's handle /// @param warnings A list of warning strings from the datafiles /// @details Returns a list of warning strings contained within the data files, typically from the data file import convertors. /// @fn BError Bds::DataAddAccess::dataSeekBlock /// @param dataHandle The opened data set's handle /// @param channel The channel number. 0 for all channels. /// @param segment The segment number. 0 for all segments /// @param time The time of a sample to search for /// @param blockNumber The returned block number /// @details This seeks for the a DataBlock in the set of files that contains a smaple for the time provided. /// If channel is other than 0 then it seeks for a DataBlock for the given channel. If the data is sample multiplexed a Channel number of 0 can be given /// which will return the location of a dataBlock containing all of the Channels. /// If Segment is 0 then the block number returned is referenced to the start of the set of files. If a particular segment number is given then /// the seek and the returned block number is within that segment. /// @fn BError Bds::DataAddAccess::dataGetBlock /// @param dataHandle The opened data set's handle /// @param channel The channel number. 0 for all channels. /// @param segment The segment number. 0 for all segments /// @param blockNumber The block number to fetch /// @param dataBlock The returned data block /// @details This returns the given block number from the set of opened data files. /// If channel is other than 0 then it will return the data for the given channel number. If the data is sample multiplexed a Channel number of 0 can be given /// which will return a DataBlock with Sensor data for all of the channels. /// If Segment is 0 then the block number is referenced to the start of the set of files. If a particular segment number is given then /// the returned block number is from within that segment. /// @fn BError Bds::DataAddAccess::dataFormattedRead /// @param dataHandle The opened data set's handle /// @param number The maximum number of Bytes to read /// @param data The set of data bytes in the requested format /// @details Given a handle to a set of data files opened for read in an external data format supported by the BDS data converters, read the raw formated data bytes from the converted file. /// @fn BError Bds::DataAddAccess::dataRealtimeConfig /// @param enable Enable/disable the sending of a real-time data stream /// @param sel The selection of channels to send /// @details This function has yet to be implemented. It is designed to enable or disable the sening of a stream of data from the BdsServer to a data viewing client. /// @fn BError Bds::DataAddAccess::dataRealtimeGet /// @param numBlocks How many blocks to return at a time /// @param numBlocksAvailable The number of blocks available in this stream /// @param dataBlocks A list of the DataBlocks /// @details This function has yet to be implemented. It is designed to return a set of real-time DataBlocks from the BdsServer to a data viewing client. /// @fn BError Bds::DataAddAccess::noteGetList /// @param sel Channels selection /// @param notes The returned Notes /// @details Uses the Selection's Network:Station:Channel:Source fields to select a list of Notes. /// @fn BError Bds::DataAddAccess::logGetList /// @param sel Log selection /// @param logs The returned Log /// @details Uses the LogSelect to select a set of system logs and return these. /// @fn BError Bds::DataAddAccess::logAppend /// @param type The log entries type: error, warning, notice, debug or all. /// @param priority The log events priority from 0 to 5 with 5 being the highest priority /// @param subSystem The subsystem the log entry is from /// @param title A title for the log entry /// @param description A more detailed description of the log entry /// @details This allows BDS xclients, perhaps data import clients, to add BDS system log entries. /// @fn BError Bds::DataAddAccess::statisticsGet /// @param info A dictionary of BdsServer statistics /// @details This returns runtime statistics from the BdsServer /// @fn BError Bds::DataAddAccess::serverConfigurationGet /// @param info A dictionary of BdsServer configuration entries /// @details This returns the list of server configuration parameters. /// @fn BError Bds::DataAddAccess::dataFormatGetList /// @param formats A list of all data file formats /// @details This returns the list of all of the data file formats supported by the BdsServer's data convertors. /// @fn BError Bds::DataAddAccess::transactionStart /// @details Starts a database transaction. A database transaction allows an atomic update of a set of database parameters with the option to abort the whole change. /// @fn BError Bds::DataAddAccess::transactionStart /// @param abort Abort or complete the transaction normally /// @details Completes a database transaction with an option to abort the changes. /// @fn BError Bds::DataAddAccess::modeSet /// @param mode The new server mode /// @param previousMode The current server mode returned /// @details Changes the mode of a BdsServer's operation. A BdsServer can be in ModeMaster or ModeSlave modes. /// In ModeSlave it will act as a read only BdsServer which can be used for resiliance, data protection or for peerformance purposes. /// @fn BError Bds::DataAddAccess::modeSnapshotPause /// @param on Enabvle/disable pause /// @details Preforms a snapshot pause. When in this mode all changes to the database and data files will be blocked untill the end of the pause. /// This allows a backup to be performed with consistant files. /// @fn BError Bds::DataAddAccess::clean /// @param cleanOptions Clean options. This has the options logs, changes and deletedFiles /// @details This function can be used to clean up old data. It should be called once in a while to perform this work. /// It will clean the given items that are over a year old. /// @fn BError Bds::DataAddAccess::databaseBackup /// @param ref Reference and file name component /// @details This will perform a complede BDS database backup into a file with the given reference name. /// @fn BError Bds::DataAddAccess::databaseRestore /// @param ref Reference and file name component /// @param type The typed of database tables to restore. Can be admin, data, metadata or all /// @details This will perform a restore of the selected sets of database tables /// @fn BError Bds::DataAddAccess::sqlQuery /// @param query The SQL query /// @param result A list of the returned strings from the database query /// @details This will perform a raw database SQL query. Use with caution! /// @fn BError Bds::DataAddAccess::extraCall /// @param function Integer number of an additional function /// @param args Parameters to the function is string form /// @param result return from the function in string form /// @details This has not been implemented but is there to add new functions to the API prior to a full API update /// @class Bds::DataAccess /// @details To use this BdsServer access object you would create one like "DataAccess bds;". /// Then you would connect it to a particular BdsServer running on a particular host using the connectService(in String) function. /// Once connected you need to login to the BdsServer as a particular user using the connect(in String user, in String password). /// After your have successfully logged in you can use the various objects methods. These result in a remote procedure call (RPC) to the BdsServer which /// Will imlement the function and return any data and normally an errors status (BError). /// @fn Bds::DataAccess::DataAccess /// @brief BDS RPC access class. /// @param name The URL of the remote BOAP object name to connect to. /// @details This object constructor takes the name of the remote object to connect to. However this is normally passed as "" as the connectService() function is normally used to perform the actual remote connection. /// @fn BError Bds::DataAccess::validateUser /// @param user The user's name /// @param email The users email address /// @details Checks to see if the user as named exsists or if just the email address is provided, if any user with that email address exists. /// @fn BError Bds::DataAccess::setUser /// @param user The user's name /// @param email The users email address /// @details Changes the connection to be logged in as the given user by their user name or email address. /// This function will only be allowed if the current user is in the userSet group. The bdsAutodrm user normally has this set so it can change /// the BdsServer's connection to be that of the BdsAutodrm user for example. /// @fn BError Bds::DataAccess::userGetList /// @param users The returned list of all users /// @details This returns the complete list of users on the system /// @fn BError Bds::DataAccess::getSelectionInfo /// @param group The type of selection info requested. Can be SelectionGroupData to get selections for Sensor data, /// SelectionGroupMetaData for Metadata selectrions and SelectionGroupDataWithCount as for SelectionGroupData but alos returns the total number of DataChannels. /// @param selectionIn The current selection /// @param selectionInfo The returned selection information /// @details Used for selection systems such as that within a Gui to restrict the options available given partial selection parameters. /// Given a basic Selection returns all of the Selection options available based on the Sensor data or Metadata in the BDS. /// For example if the selectionIn defines one particular Network and one particular Station, the getSelectionInfo function will return a list of Channels /// and Sources for that base selection. /// @fn BError Bds::DataAccess::getSelections /// @param group The type of selection info requested. Currently ignored. /// @param selectionIn The selection which may include regular expressions and Station arrays. /// @param selectionOut The full Sensor data selection after regular expressions have been expanded and any Array's exapanded into a list of Stations. /// @details This is used to expand a Sensor data Selection to a full Selection list. /// @fn BError Bds::DataAccess::stationGetList /// @param sel The Selection /// @param stations The list of Stations matching the Selection. /// @details This uses the Network:Station parts of the Selection object to return a list of matching Stations. /// @fn BError Bds::DataAccess::locationGetList /// @param sel The Selection /// @param locations The list of Locations matching the Selection. /// @details This uses the Network:Station and optionaly the Channel parts of the Selection object to return a list of matching Stations. /// The Selection.locationSelect parameter can be set to LocationSelectAll, LocationSelectStation or LocationSelectChannel. /// If set to LocationSelectStation will return the locations of the Stations matched. /// If set to LocationSelectChannel will return the locations of the Channels matched. /// If set to LocationSelectAll (The default) will return the locations of the Channels matched if they have Locations or otherwise that of the Stations. /// @fn BError Bds::DataAccess::channelGetList /// @param sel The Selection /// @param channels The list of Channels matching the Selection. /// @details If the selection.channelId is set to a value other than 0, this will return a list of one Channel which matches that id. /// Otherwise it will return a list of Channels matchin the Network:Station:Channel regular expression fields of the selection. /// @fn BError Bds::DataAccess::channelInstrumentGetList /// @param sel The Selection /// @param channelInstruments The list of ChannelInstruments matching the Selection. /// @details This uses the Network:Station:Channel:Source fields of the Selection to return a list of matching Channel Instruments. /// @fn BError Bds::DataAccess::digitiserGetList /// @param sel The Selection /// @param digitisers The list of Digitisers matching the Selection. /// @details If selection.digitiserId is set, then return the single matching Digitiser. Otherwise use the Selection's Network:Station:Channel:Source fields to return a list of matching Digitisers. /// @fn BError Bds::DataAccess::sensorGetList /// @param sel The Selection /// @param sensors The list of Sensors matching the Selection. /// @details If selection.sensorId is set, then return the single matching Sensor. Otherwise use the Selection's Network:Station:Channel:Source fields to return a list of matching Sensors. /// @fn BError Bds::DataAccess::responseGetList /// @param sel The Selection /// @param responses The list of Responses matching the Selection. /// @details Use the Selection's Network:Station:Channel:Source fields to return a list of matching Responses. /// @fn BError Bds::DataAccess::eventGetList /// @param sel The Selection /// @param events The list of Events matching the Selection. /// @details If sel.id or sel.eventId is set then return the Event with this ID. /// Otherwise if sel.name is set return an Event with a title matching this regular expression between sel.startTime and sel.endTime.. /// Otherwise match any events between sel.startTime and sel.endTime. /// @fn BError Bds::DataAccess::specialChannelGetList /// @param sel The Selection /// @param specialChannels The list of SpecialChannels matching the Selection. /// @details This will return a list of SpecialChannels matchin the Network:Station:Channel regular expression fields of the selection. /// @fn BError Bds::DataAccess::metadataGetChannelInfo /// @param sel Channels selection /// @param channelInfos Metadata information for the channels /// @details This function is designed to help when exporting data from the BDS. It will attempt to gather all of the Metadata present for the Channels selected. /// Depending on the dataType of the selected Channels it will check that the expected Metadata is present and if not return an Error. /// For Channels of dataType "seismic" it will check that the following Metadata information exists: Station, Channel, Location. Calibration, Response, ChannelInstrument. /// For each of the selected Channels there will be an array of ChannelInfo objects. The BdsServer will segment the Metadata in time periods at each point an of this Metadata is changed. /// This each ChannelInfo object will return a set of Metadata over a time period that has no change in Metadata. When exporting data it can be time segmented to /// match this. /// @fn BError Bds::DataAccess::metadataGetFormatted /// @param sel Channels selection /// @param format The requested Metadata output format. This should match a format specified by any of the BDS data convertors. /// @param data The raw file data for the format given in bytes. /// @details This function gathers all of the Metadata for the channels matching the Selection and then finds a suitable BDS data format conertor to export this Metadata in /// the chosen format. The resultion array of Byte data can be written to a suitable file. /// @fn BError Bds::DataAccess::dataFileGetList /// @param sel Channels selection /// @param dataFiles The returned DataFiles /// @details If sel.id is set, then returns the single DataFile matching this id. /// Otherwise uses the Selection's Network:Station:Channel:Source fields to select a list of DataFiles. /// @fn BError Bds::DataAccess::dataChannelGetList /// @param sel Channels selection /// @param dataChannels The returned DataChannel /// @details Uses the Selection's Network:Station:Channel:Source fields to select a list of DataChannels. /// @fn BError Bds::DataAccess::dataAvailability /// @param sel The selection information /// @param num The number of availability time segments to return. /// @param dataAvailChans Information on the availablility of sensor data for the selected channel /// @details This function will return a list of Sensor data availability information for the selected Channels. /// If num > 0 then it will restrict the number of time segments to that number. The time segments will be linearly spaced in time. /// If num ==0 then the system will return a data availabliliy segment for each DataChannel continuous segment. This can be slow and return a very large number of segments. /// @fn BError Bds::DataAccess::dataSearch /// @param selection Channel Selection information /// @param dataInfo Sensor data selection information with data segmented by actual data file segments with extra information if available /// @details This will perform a search for Sensor data matching the Selection. Be careful with the selction as their could be a lot of data matching /// that will then hit resource limits. There are restrictions on the maximum time range allowed (MaxTimePeriod) and the maximum DataChannel segments returned (MaxNumChannels). /// The return DataInfo object can be interidated for information on the data, such as sampleRates and/or used in the dataOpen() function /// for actual access to the Sensor data. /// @fn BError Bds::DataAccess::dataGetChannelInfo /// @param dataInfo Data selection /// @param channelInfos Metadata information for the channels /// @details This function returns all of the Metadata for the given Channels specified in the dataInfo selection. It uses the metadataGetChannelInfo() function /// converting the DataInfo selection to a more general Selection first. /// @fn BError Bds::DataAccess::dataOpen /// @param dataInfo Data selection defining the Sensor data Channels /// @param mode The open mode. This can be "r" for read access, "w" for write access and "aday" to append to a day file. /// @param format This is the format to use. It can be "API-SM" for multiplexed by sample or "API-CM" for multiplexed by channel. For reads it can also be one of the BDS data convertors supported formats. /// @param flags Bit set of DataFlags. Can include: DataFlagClipDataToTime, DataFlagClipDataToChannels, DataFlagMergeSegments and DataFlagNoMetadata /// @param dataHandle The returned data handle to access this data set /// @details This function opens a set of Sensor data files in the BdsServer for read, write or append access. /// When the format is "API-SM" or "API-CM" then the raw data blocks can be accessed using the dataSeekBlock() and dataGetBlock() functions. Note /// that the "API-SM" format requires the Channels selected to be synchonously sampled and so can only be used for certain import/export data formats where this is the case. /// The flags are used when reading data. Normaly whole contigous DataBlocks are returned. The actual starttime and endtime of the overall data may thus be before and after the selection. /// The DataFlagClipDataToTime "clips" the first and last blocks, removing samples, so the time match the actual selection. /// The DataFlagClipDataToChannels "clips" the blocks so that all of the Channels contain data over the selection period as some Channels otherwise could be missing /// data for a portion of the Selection. /// DataFlagMergeSegments mergese data segments that have matching end and start times into one continuous segment. /// DataFlagNoMetadata ignores Metadata when exporting data. /// @fn BError Bds::DataAccess::dataGetInfo /// @param dataHandle The opened data set's handle /// @param infoExtra A boolean flag to say to include the extra Metadata containwed within the files /// @param dataInfo The resulting fully filled out DataInfo describing the data. /// @details This functions returns fuller, more detailed, information on the Sensor data using Metadata stored within the data files themselves. /// The BDS data format files can store an extensive amount of Metadata from the various import formats supported. A fair amount of this Metadata is /// freeform and this is for general information purposes only. /// The returned sampleRate is the samplerate calculated on the actual data samples taking into account start and end times as well as actual numbers of continuous samples. /// The DataInfo returned has a set of time segmented information per Channel. Each of the DataInfo segments defines a cotigous set of data with no time discontinuities. /// @fn BError Bds::DataAccess::dataGetNotes /// @param dataHandle The opened data set's handle /// @param notes A list of Notes on the data /// @details Returns a list of system and user added notes for the data from the database. /// @fn BError Bds::DataAccess::dataGetWarnings /// @param dataHandle The opened data set's handle /// @param warnings A list of warning strings from the datafiles /// @details Returns a list of warning strings contained within the data files, typically from the data file import convertors. /// @fn BError Bds::DataAccess::dataSeekBlock /// @param dataHandle The opened data set's handle /// @param channel The channel number. 0 for all channels. /// @param segment The segment number. 0 for all segments /// @param time The time of a sample to search for /// @param blockNumber The returned block number /// @details This seeks for the a DataBlock in the set of files that contains a smaple for the time provided. /// If channel is other than 0 then it seeks for a DataBlock for the given channel. If the data is sample multiplexed a Channel number of 0 can be given /// which will return the location of a dataBlock containing all of the Channels. /// If Segment is 0 then the block number returned is referenced to the start of the set of files. If a particular segment number is given then /// the seek and the returned block number is within that segment. /// @fn BError Bds::DataAccess::dataGetBlock /// @param dataHandle The opened data set's handle /// @param channel The channel number. 0 for all channels. /// @param segment The segment number. 0 for all segments /// @param blockNumber The block number to fetch /// @param dataBlock The returned data block /// @details This returns the given block number from the set of opened data files. /// If channel is other than 0 then it will return the data for the given channel number. If the data is sample multiplexed a Channel number of 0 can be given /// which will return a DataBlock with Sensor data for all of the channels. /// If Segment is 0 then the block number is referenced to the start of the set of files. If a particular segment number is given then /// the returned block number is from within that segment. /// @fn BError Bds::DataAccess::dataFormattedRead /// @param dataHandle The opened data set's handle /// @param number The maximum number of Bytes to read /// @param data The set of data bytes in the requested format /// @details Given a handle to a set of data files opened for read in an external data format supported by the BDS data converters, read the raw formated data bytes from the converted file. /// @fn BError Bds::DataAccess::dataRealtimeConfig /// @param enable Enable/disable the sending of a real-time data stream /// @param sel The selection of channels to send /// @details This function has yet to be implemented. It is designed to enable or disable the sening of a stream of data from the BdsServer to a data viewing client. /// @fn BError Bds::DataAccess::dataRealtimeGet /// @param numBlocks How many blocks to return at a time /// @param numBlocksAvailable The number of blocks available in this stream /// @param dataBlocks A list of the DataBlocks /// @details This function has yet to be implemented. It is designed to return a set of real-time DataBlocks from the BdsServer to a data viewing client. /// @fn BError Bds::DataAccess::noteGetList /// @param sel Channels selection /// @param notes The returned Notes /// @details Uses the Selection's Network:Station:Channel:Source fields to select a list of Notes. /// @fn BError Bds::DataAccess::logGetList /// @param sel Log selection /// @param logs The returned Log /// @details Uses the LogSelect to select a set of system logs and return these. /// @fn BError Bds::DataAccess::logAppend /// @param type The log entries type: error, warning, notice, debug or all. /// @param priority The log events priority from 0 to 5 with 5 being the highest priority /// @param subSystem The subsystem the log entry is from /// @param title A title for the log entry /// @param description A more detailed description of the log entry /// @details This allows BDS xclients, perhaps data import clients, to add BDS system log entries. /// @fn BError Bds::DataAccess::statisticsGet /// @param info A dictionary of BdsServer statistics /// @details This returns runtime statistics from the BdsServer /// @fn BError Bds::DataAccess::serverConfigurationGet /// @param info A dictionary of BdsServer configuration entries /// @details This returns the list of server configuration parameters. /// @fn BError Bds::DataAccess::dataFormatGetList /// @param formats A list of all data file formats /// @details This returns the list of all of the data file formats supported by the BdsServer's data convertors. /// @fn BError Bds::DataAccess::transactionStart /// @details Starts a database transaction. A database transaction allows an atomic update of a set of database parameters with the option to abort the whole change. /// @fn BError Bds::DataAccess::transactionStart /// @param abort Abort or complete the transaction normally /// @details Completes a database transaction with an option to abort the changes. /// @fn BError Bds::DataAccess::modeSet /// @param mode The new server mode /// @param previousMode The current server mode returned /// @details Changes the mode of a BdsServer's operation. A BdsServer can be in ModeMaster or ModeSlave modes. /// In ModeSlave it will act as a read only BdsServer which can be used for resiliance, data protection or for peerformance purposes. /// @fn BError Bds::DataAccess::modeSnapshotPause /// @param on Enabvle/disable pause /// @details Preforms a snapshot pause. When in this mode all changes to the database and data files will be blocked untill the end of the pause. /// This allows a backup to be performed with consistant files. /// @fn BError Bds::DataAccess::clean /// @param cleanOptions Clean options. This has the options logs, changes and deletedFiles /// @details This function can be used to clean up old data. It should be called once in a while to perform this work. /// It will clean the given items that are over a year old. /// @fn BError Bds::DataAccess::databaseBackup /// @param ref Reference and file name component /// @details This will perform a complede BDS database backup into a file with the given reference name. /// @fn BError Bds::DataAccess::databaseRestore /// @param ref Reference and file name component /// @param type The typed of database tables to restore. Can be admin, data, metadata or all /// @details This will perform a restore of the selected sets of database tables /// @fn BError Bds::DataAccess::sqlQuery /// @param query The SQL query /// @param result A list of the returned strings from the database query /// @details This will perform a raw database SQL query. Use with caution! /// @fn BError Bds::DataAccess::extraCall /// @param function Integer number of an additional function /// @param args Parameters to the function is string form /// @param result return from the function in string form /// @details This has not been implemented but is there to add new functions to the API prior to a full API update /// @fn BError Bds::DataFile::open /// @param fileName The filename to open. Can be a full path or relative path to the current working directory /// @param mode The open mode. Can be "r" or "w". /// @details Opens a file of the gievn file format /// @fn BError Bds::DataFile::setFormat /// @param format The data files format /// @details When a data converter support multiple sub-format, this chooses the one to use. /// @fn BError Bds::DataFile::getFeatures /// @details Returns a bit mask of the data converters featurs from the set FeatureCanWrite = 0x01 and FeatureCanRead = 0x02 /// @fn BError Bds::DataFile::getFixesInfo /// @details returns a human readable string describing the fixes to currupted files this data converter can implement when the ReadOptionFixCorruptions option is used /// @fn BError Bds::DataFile::setInfo /// @param dataInfo Info on the Sensor data channels to be written /// @param channelInfos The metadata for the data channels /// @param options A bitmask of options including: WriteOptionSensorData, WriteOptionNoMetadata /// WriteOptionSensorData: Writes Sensor data to the file /// WriteOptionNoMetadata: Disable the writing of Metadata /// @details This function provides the information to create and write to a data file of this given format. /// @fn BError Bds::DataFile::start /// @param channel The Channel number, 0 for all channels if multiple channel /// @param segment The data segment number /// @details This starts writing a contiguous time segment of data to the file. It might write a section header etc depending of the file format /// @fn BError Bds::DataFile::writeData /// @param data A block of data /// @details This writes a block of data to the file /// @fn BError Bds::DataFile::end /// @details This defines the end of a data segment. /// @fn BError Bds::DataFile::flush /// @details Makes sure all of the files contents is flushed from RAM to the disk. /// @fn BError Bds::DataFile::getFormat /// @param format The returned format /// @details Returns the name of the sub-format in use /// @fn BError Bds::DataFile::getInfo /// @param dataInfo Info on the Sensor data channels to be written /// @param options A bitmask of options including: ReadOptionValidate = 0x01, ReadOptionFileNameProcess = 0x02, ReadOptionFixCorruptions = 0x04, ReadOptionReorder = 0x08, ReadOptionDeleteDuplicates = 0x10, ReadOptionInfoExtra = 0x20, ReadOptionIgnoreSamplerate = 0x40, ReadOptionPrintBlocks = 0x80, ReadOptionFixSampleRate = 0x100 /// @param errors Returns a list of errors and/or warnings /// ReadOptionValidate: performs data file validation /// ReadOptionFileNameProcess: Validate the filename for particular file formats /// ReadOptionFixCorruptions: Fix know file curruptions /// ReadOptionReorder: Re-order blocks into time order /// ReadOptionDeleteDuplicates: Delete duplicate blocks where they are completely duplicate in startTime and data. /// ReadOptionInfoExtra: Read the extra string Metadata information specific to the format /// ReadOptionIgnoreSamplerate: Ignore samplerate differences /// ReadOptionPrintBlocks: debug option to print information on the blocks to stdout /// ReadOptionFixSampleRate: Fors specific formats fixe curruptions in the samplerate gieven /// @details This function scans the file and returns detailed Metadata from the blocks in the file. /// @fn BError Bds::DataFile::seekBlock /// @param channel The channel number. 0 for all channels. /// @param segment The segment number. 0 for all segments /// @param time The time of a sample to search for /// @param blockNumber The returned block number /// @param sampleNumber The sample number inside the block (based on sampleRate) /// @param data The matched DataBlock /// @details This seeks for the a DataBlock in the file that contains a sample for the time provided. /// If channel is other than 0 then it seeks for a DataBlock for the given channel. If the data is sample multiplexed a Channel number of 0 can be given /// which will return the location of a dataBlock containing all of the Channels. /// If Segment is 0 then the block number returned is referenced to the start of the set of files. If a particular segment number is given then /// the seek and the returned block number is within that segment. /// @fn BError Bds::DataFile::readData /// @param channel The channel number. 0 Means all channels /// @param segment The segment number. 0 Means all segments /// @param blockNumber The block number. This starts from 0. /// @param dataBlock The returned DataBlock /// @details This function is used to read a data block from the file. /// @fn BError Bds::DataFile::getMetaData /// @param channelInfos The Metadata in the file is returned in this /// @param options This operators similarly to the getInfo options although some features are not relevent /// @param errors Returns a list of errors and/or warnings /// @details This function is similar to getInfo except that it returns the list of Channel metadata in the file if any. Only certain formats can provide this. /// @fn BError Bds::AdminAccess:: /// @param /// @details