From 12dfb9ee5dc6948ae05f5ce9f7899f52a2b818cd Mon Sep 17 00:00:00 2001 From: Junhao Liao Date: Fri, 8 Nov 2024 09:19:27 -0500 Subject: [PATCH] Rename `IrStreamType` -> `StreamType` in the `ir` namespace. --- src/clp_ffi_js/ir/StreamReader.cpp | 6 +++--- src/clp_ffi_js/ir/StreamReader.hpp | 4 ++-- src/clp_ffi_js/ir/StructuredIrStreamReader.hpp | 4 ++-- src/clp_ffi_js/ir/UnstructuredIrStreamReader.hpp | 4 ++-- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/clp_ffi_js/ir/StreamReader.cpp b/src/clp_ffi_js/ir/StreamReader.cpp index 331bd330..d78b7e75 100644 --- a/src/clp_ffi_js/ir/StreamReader.cpp +++ b/src/clp_ffi_js/ir/StreamReader.cpp @@ -119,9 +119,9 @@ EMSCRIPTEN_BINDINGS(ClpStreamReader) { emscripten::register_type("{timestampKey: string} | null"); // JS types used as outputs - emscripten::enum_("IrStreamType") - .value("STRUCTURED", clp_ffi_js::ir::IrStreamType::Structured) - .value("UNSTRUCTURED", clp_ffi_js::ir::IrStreamType::Unstructured); + emscripten::enum_("IrStreamType") + .value("STRUCTURED", clp_ffi_js::ir::StreamType::Structured) + .value("UNSTRUCTURED", clp_ffi_js::ir::StreamType::Unstructured); emscripten::register_type( "Array<[string, number, number, number]>" ); diff --git a/src/clp_ffi_js/ir/StreamReader.hpp b/src/clp_ffi_js/ir/StreamReader.hpp index 4c80629d..4af40a4f 100644 --- a/src/clp_ffi_js/ir/StreamReader.hpp +++ b/src/clp_ffi_js/ir/StreamReader.hpp @@ -19,7 +19,7 @@ EMSCRIPTEN_DECLARE_VAL_TYPE(ReaderOptions); EMSCRIPTEN_DECLARE_VAL_TYPE(DecodedResultsTsType); EMSCRIPTEN_DECLARE_VAL_TYPE(FilteredLogEventMapTsType); -enum class IrStreamType : uint8_t { +enum class StreamType : uint8_t { Structured, Unstructured, }; @@ -57,7 +57,7 @@ class StreamReader { auto operator=(StreamReader&&) -> StreamReader& = delete; // Methods - [[nodiscard]] virtual auto get_ir_stream_type() const -> IrStreamType = 0; + [[nodiscard]] virtual auto get_ir_stream_type() const -> StreamType = 0; /** * @return The number of events buffered. diff --git a/src/clp_ffi_js/ir/StructuredIrStreamReader.hpp b/src/clp_ffi_js/ir/StructuredIrStreamReader.hpp index c728c1e9..e93dee03 100644 --- a/src/clp_ffi_js/ir/StructuredIrStreamReader.hpp +++ b/src/clp_ffi_js/ir/StructuredIrStreamReader.hpp @@ -149,8 +149,8 @@ class StructuredIrStreamReader : public StreamReader { // Delete move assignment operator since it's also disabled in `clp::ir::LogEventDeserializer`. auto operator=(StructuredIrStreamReader&&) -> StructuredIrStreamReader& = delete; - [[nodiscard]] auto get_ir_stream_type() const -> IrStreamType override { - return IrStreamType::Structured; + [[nodiscard]] auto get_ir_stream_type() const -> StreamType override { + return StreamType::Structured; } [[nodiscard]] auto get_num_events_buffered() const -> size_t override; diff --git a/src/clp_ffi_js/ir/UnstructuredIrStreamReader.hpp b/src/clp_ffi_js/ir/UnstructuredIrStreamReader.hpp index 9f921df4..b4f22107 100644 --- a/src/clp_ffi_js/ir/UnstructuredIrStreamReader.hpp +++ b/src/clp_ffi_js/ir/UnstructuredIrStreamReader.hpp @@ -56,8 +56,8 @@ class UnstructuredIrStreamReader : public StreamReader { clp::Array data_array ) -> UnstructuredIrStreamReader; - [[nodiscard]] auto get_ir_stream_type() const -> IrStreamType override { - return IrStreamType::Unstructured; + [[nodiscard]] auto get_ir_stream_type() const -> StreamType override { + return StreamType::Unstructured; } [[nodiscard]] auto get_num_events_buffered() const -> size_t override;