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

use strict;

package Raritan::RPC::net::EthSettings_2_0_0;

use Raritan::RPC::net::EthLinkMode;
use Raritan::RPC::net::EapAuthSettings_3_0_0;

sub encode {
    my ($in) = @_;
    my $encoded = {};
    $encoded->{'linkMode'} = Raritan::RPC::net::EthLinkMode::encode($in->{'linkMode'});
    $encoded->{'authType'} = $in->{'authType'};
    $encoded->{'eap'} = Raritan::RPC::net::EapAuthSettings_3_0_0::encode($in->{'eap'});
    return $encoded;
}

sub decode {
    my ($agent, $in) = @_;
    my $decoded = {};
    $decoded->{'linkMode'} = Raritan::RPC::net::EthLinkMode::decode($agent, $in->{'linkMode'});
    $decoded->{'authType'} = $in->{'authType'};
    $decoded->{'eap'} = Raritan::RPC::net::EapAuthSettings_3_0_0::decode($agent, $in->{'eap'});
    return $decoded;
}

1;
