// file: ks-lib/src/decoder/orderbook/openbook_v2.rs // version: 6 //! Reserved protocol decoder for `orderbook_openbook_v2`. /// Reserved decoder for the `orderbook_openbook_v2` program surface. #[derive(Clone, Debug, Default)] pub struct DcOrderbookOpenbookV2Decoder; impl crate::DcApiProtocolDecoder for crate::DcOrderbookOpenbookV2Decoder { fn decoder_name(&self) -> &'static str { return "ks-lib-decoder.orderbook.openbook_v2"; } fn decoder_version(&self) -> &'static str { return env!("CARGO_PKG_VERSION"); } fn program_ids(&self) -> &'static [&'static str] { return &[ks_program_ids::ORDERBOOK_OPENBOOK_V2_PROGRAM_ID]; } fn supports_observation( &self, observation: &crate::MdProgramObservation, ) -> crate::DcApiDecoderSupport { if crate::DcApiProtocolDecoder::handles_program_id(self, &observation.program_id) { return crate::DcApiDecoderSupport::Maybe; } return crate::DcApiDecoderSupport::No; } fn decode_observation( &self, _observation: &crate::MdProgramObservation, ) -> ks_core::Result> { return std::result::Result::Ok(std::vec::Vec::new()); } }