Skip to content

Commit

Permalink
Rename spectrum::signal to spectrum::bindata
Browse files Browse the repository at this point in the history
  • Loading branch information
mobiusklein committed Dec 6, 2023
1 parent 2a00668 commit 05b99e0
Show file tree
Hide file tree
Showing 16 changed files with 17 additions and 17 deletions.
2 changes: 1 addition & 1 deletion src/io/mgf.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ use crate::meta::{
DataProcessing, FileDescription, InstrumentConfiguration, MSDataFileMetadata, Software,
};
use crate::params::{ControlledVocabulary, Param, ParamDescribed, ParamLike};
use crate::spectrum::signal::{
use crate::spectrum::bindata::{
vec_as_bytes, ArrayType, BinaryArrayMap, BinaryDataArrayType, BuildArrayMapFrom,
BuildFromArrayMap, DataArray,
};
Expand Down
5 changes: 2 additions & 3 deletions src/io/mzml/reader.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,9 @@ use crate::meta::InstrumentConfiguration;
use crate::meta::{DataProcessing, MSDataFileMetadata, Software};
use crate::params::{Param, ParamList, Unit};
use crate::spectrum::scan_properties::*;
use crate::spectrum::signal::BuildArrayMapFrom;
use crate::spectrum::signal::BuildFromArrayMap;
use crate::spectrum::signal::{
use crate::spectrum::bindata::{
ArrayType, BinaryArrayMap, BinaryCompressionType, BinaryDataArrayType, DataArray,
BuildFromArrayMap, BuildArrayMapFrom
};
use crate::spectrum::spectrum::{
CentroidPeakAdapting, CentroidSpectrumType, DeconvolutedPeakAdapting, MultiLayerSpectrum,
Expand Down
2 changes: 1 addition & 1 deletion src/io/mzml/writer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ use crate::meta::{
Software,
};
use crate::params::{ControlledVocabulary, Param, ParamCow, ParamDescribed, ParamLike, Unit};
use crate::spectrum::signal::{
use crate::spectrum::bindata::{
to_bytes, ArrayRetrievalError, ArrayType, BinaryArrayMap, BinaryCompressionType,
BinaryDataArrayType, BuildArrayMapFrom, ByteArrayView, DataArray,
};
Expand Down
2 changes: 1 addition & 1 deletion src/io/mzmlb/reader.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ use crate::prelude::{MSDataFileMetadata, ParamLike};

use crate::meta::{DataProcessing, FileDescription, InstrumentConfiguration, Software};
use crate::params::{ControlledVocabulary, Param};
use crate::spectrum::signal::{
use crate::spectrum::bindata::{
as_bytes, delta_decoding, linear_prediction_decoding, ArrayRetrievalError,
BinaryCompressionType, BinaryDataArrayType, ByteArrayView, ByteArrayViewMut, DataArray,
};
Expand Down
2 changes: 1 addition & 1 deletion src/io/mzmlb/writer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ use crate::prelude::MSDataFileMetadata;
use crate::io::traits::ScanWriter;
use crate::meta::{DataProcessing, FileDescription, InstrumentConfiguration, Software};
use crate::params::ControlledVocabulary;
use crate::spectrum::signal::{
use crate::spectrum::bindata::{
ArrayRetrievalError, BinaryDataArrayType, BuildArrayMapFrom, ByteArrayView, DataArray,
};
use crate::spectrum::{
Expand Down
1 change: 1 addition & 0 deletions src/meta/data_processing.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#![allow(unused)]
use std::fmt::Display;

use crate::impl_param_described;
Expand Down
2 changes: 1 addition & 1 deletion src/prelude.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@ pub use crate::io::traits::{
pub use crate::meta::MSDataFileMetadata;
pub use crate::params::{ParamDescribed, ParamLike};
pub use crate::spectrum::{IonProperties, PrecursorSelection, SpectrumLike};
pub use crate::spectrum::signal::{ByteArrayView, ByteArrayViewMut, BuildArrayMapFrom, BuildFromArrayMap};
pub use crate::spectrum::bindata::{ByteArrayView, ByteArrayViewMut, BuildArrayMapFrom, BuildFromArrayMap};
pub use std::convert::TryInto;
pub use std::io::prelude::*;
4 changes: 2 additions & 2 deletions src/spectrum.rs
Original file line number Diff line number Diff line change
Expand Up @@ -52,12 +52,12 @@ for spectrum in reader {
*/

pub(crate) mod scan_properties;
pub mod signal;
pub mod bindata;
pub(crate) mod spectrum;
pub(crate) mod chromatogram;

pub use crate::spectrum::scan_properties::*;
pub use crate::spectrum::signal::{ArrayType, BinaryArrayMap, BinaryDataArrayType, DataArray};
pub use crate::spectrum::bindata::{ArrayType, BinaryArrayMap, BinaryDataArrayType, DataArray};
pub use crate::spectrum::spectrum::{
SpectrumLike, PeakDataLevel,
SpectrumConversionError, SpectrumProcessingError,
Expand Down
4 changes: 2 additions & 2 deletions src/spectrum/signal.rs → src/spectrum/bindata.rs
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
mod bindata;
mod array;
mod conversion;
mod encodings;
mod map;
mod traits;

pub use bindata::{DataArray, DataArraySlice};
pub use array::{DataArray, DataArraySlice};
pub use encodings::{
as_bytes, delta_decoding, delta_encoding, linear_prediction_decoding,
linear_prediction_encoding, to_bytes, vec_as_bytes, ArrayRetrievalError, ArrayType,
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ use mzpeaks::{

use crate::utils::neutral_mass;

use super::bindata::DataArray;
use super::array::DataArray;
use super::encodings::{
ArrayRetrievalError, ArrayType, BinaryCompressionType, BinaryDataArrayType,
};
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/spectrum/signal/map.rs → src/spectrum/bindata/map.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ use rayon::prelude::*;

use mzpeaks::Tolerance;

use super::bindata::DataArray;
use super::array::DataArray;
use super::encodings::{ArrayType, ArrayRetrievalError, BinaryCompressionType};
use super::traits::{ByteArrayView, ByteArrayViewMut};

Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/spectrum/chromatogram.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use crate::params::Param;
use crate::spectrum::scan_properties::{
Precursor, ScanPolarity, ChromatogramType, ChromatogramDescription,
};
use super::signal::{ArrayType, BinaryArrayMap, ArrayRetrievalError, ByteArrayView};
use super::bindata::{ArrayType, BinaryArrayMap, ArrayRetrievalError, ByteArrayView};



Expand Down
4 changes: 2 additions & 2 deletions src/spectrum/spectrum.rs
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,9 @@ use crate::params::ParamList;
use crate::spectrum::scan_properties::{
Acquisition, Precursor, ScanPolarity, SignalContinuity, SpectrumDescription,
};
use crate::spectrum::signal::{ArrayType, BinaryArrayMap, BinaryDataArrayType};
use crate::spectrum::bindata::{ArrayType, BinaryArrayMap, BinaryDataArrayType};

use super::signal::{ArrayRetrievalError, BuildArrayMapFrom, BuildFromArrayMap};
use super::bindata::{ArrayRetrievalError, BuildArrayMapFrom, BuildFromArrayMap};

pub trait CentroidPeakAdapting: CentroidLike + Default {}
impl<C: CentroidLike + Default> CentroidPeakAdapting for C {}
Expand Down

0 comments on commit 05b99e0

Please sign in to comment.