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

use strict;

package Raritan::RPC::usb::Usb_1_0_2::Settings;

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

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

1;
