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

use strict;

package Raritan::RPC::pdumodel::Controller_5_0_1::MetaDataChangedEvent;

use constant typeId => "pdumodel.Controller_5_0_1.MetaDataChangedEvent:1.0.0";
use Raritan::RPC::idl::Event;
use Raritan::RPC::pdumodel::Controller_5_0_1::MetaData;
use Raritan::RPC::pdumodel::Controller_5_0_1::MetaData;

sub encode {
    my ($in) = @_;
    my $encoded = Raritan::RPC::idl::Event::encode($in);
    $encoded->{'oldMetaData'} = Raritan::RPC::pdumodel::Controller_5_0_1::MetaData::encode($in->{'oldMetaData'});
    $encoded->{'newMetaData'} = Raritan::RPC::pdumodel::Controller_5_0_1::MetaData::encode($in->{'newMetaData'});
    return $encoded;
}

sub decode {
    my ($agent, $in) = @_;
    my $decoded = Raritan::RPC::idl::Event::decode($agent, $in);
    $decoded->{'oldMetaData'} = Raritan::RPC::pdumodel::Controller_5_0_1::MetaData::decode($agent, $in->{'oldMetaData'});
    $decoded->{'newMetaData'} = Raritan::RPC::pdumodel::Controller_5_0_1::MetaData::decode($agent, $in->{'newMetaData'});
    return $decoded;
}

Raritan::RPC::Registry::registerCodecClass('pdumodel.Controller_5_0_1.MetaDataChangedEvent', 1, 0, 0, 'Raritan::RPC::pdumodel::Controller_5_0_1::MetaDataChangedEvent');
1;
