# SPDX-License-Identifier: BSD-3-Clause
#
# Copyright 2026 Raritan Inc. All rights reserved.
#
# This file was generated by IdlC from LhxParameter.idl.

use strict;

package Raritan::RPC::lhxmodel::Parameter_1_0_1::Value;

use Raritan::RPC::lhxmodel::Parameter_1_0_1::Status;

sub encode {
    my ($in) = @_;
    my $encoded = {};
    $encoded->{'timestamp'} = 1 * $in->{'timestamp'};
    $encoded->{'status'} = Raritan::RPC::lhxmodel::Parameter_1_0_1::Status::encode($in->{'status'});
    $encoded->{'value'} = 1 * $in->{'value'};
    return $encoded;
}

sub decode {
    my ($agent, $in) = @_;
    my $decoded = {};
    $decoded->{'timestamp'} = $in->{'timestamp'};
    $decoded->{'status'} = Raritan::RPC::lhxmodel::Parameter_1_0_1::Status::decode($agent, $in->{'status'});
    $decoded->{'value'} = $in->{'value'};
    return $decoded;
}

1;
