function [ rfbfile ] = rfb(pFilename)
%RFB Loads a .rfb file into memory using the tomlini function.
%   Creates a struct that contains the sections as properties.
%
%   Parameters:
%       pFilename (string) The filename to be read.
%


%% Initialize input parameter
rfbfile = false;

%% Parameter check
parameter_error = false;

if (~ischar(pFilename))
    warning([mfilename ': pFilename is not a string!']);
    parameter_error = true;
else
    % get filename details
    [pathstr, name, ext] = fileparts(pFilename);
    if (~strcmp(ext, '.rfb'))
        warning([mfilename ': Please check input parameter. Wrong file extension! Should be .rfb!']);
        parameter_error = true;
    end
end

if parameter_error
    return; % return if parameter check has not been passed successfully
else
    clear parameter_error;
end

rfbfile = artoa.load.tomlini(pFilename);

end