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

use strict;

package Raritan::RPC::usermgmt::AccountRenamed;

use constant typeId => "usermgmt.AccountRenamed:1.0.0";
use Raritan::RPC::usermgmt::AccountEvent;

sub encode {
    my ($in) = @_;
    my $encoded = Raritan::RPC::usermgmt::AccountEvent::encode($in);
    $encoded->{'newUsername'} = "$in->{'newUsername'}";
    return $encoded;
}

sub decode {
    my ($agent, $in) = @_;
    my $decoded = Raritan::RPC::usermgmt::AccountEvent::decode($agent, $in);
    $decoded->{'newUsername'} = $in->{'newUsername'};
    return $decoded;
}

Raritan::RPC::Registry::registerCodecClass('usermgmt.AccountRenamed', 1, 0, 0, 'Raritan::RPC::usermgmt::AccountRenamed');
1;
