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

use strict;

package Raritan::RPC::devsettings::Zeroconf_2_0_0::Settings;

sub encode {
    my ($in) = @_;
    my $encoded = {};
    $encoded->{'mdnsEnabled'} = ($in->{'mdnsEnabled'}) ? JSON::true : JSON::false;
    $encoded->{'llmnrEnabled'} = ($in->{'llmnrEnabled'}) ? JSON::true : JSON::false;
    return $encoded;
}

sub decode {
    my ($agent, $in) = @_;
    my $decoded = {};
    $decoded->{'mdnsEnabled'} = ($in->{'mdnsEnabled'}) ? 1 : 0;
    $decoded->{'llmnrEnabled'} = ($in->{'llmnrEnabled'}) ? 1 : 0;
    return $decoded;
}

1;
