mod bytes;
mod parse;
use crate::Operand;
use console::{network::prelude::*, program::ValueType};
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct Output<N: Network> {
operand: Operand<N>,
value_type: ValueType<N>,
}
impl<N: Network> Output<N> {
#[inline]
pub const fn operand(&self) -> &Operand<N> {
&self.operand
}
#[inline]
pub const fn value_type(&self) -> &ValueType<N> {
&self.value_type
}
}
impl<N: Network> TypeName for Output<N> {
#[inline]
fn type_name() -> &'static str {
"output"
}
}
#[cfg(test)]
mod tests {
use super::*;
use console::network::MainnetV0;
type CurrentNetwork = MainnetV0;
#[test]
fn test_output_type_name() {
assert_eq!(Output::<CurrentNetwork>::type_name(), "output");
}
}