You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: windows.rb
    path of file: ./repos/chef/lib/chef/provider/package
    
    the code of the file until where you have to start completion: #
# Author:: Bryan McLellan <btm@loftninjas.org>
# Copyright:: Copyright (c) Chef Software Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#

require_relative "../../mixin/uris"
require_relative "../../resource/windows_package"
require_relative "../package"
require_relative "../../util/path_helper"
require_relative "../../mixin/checksum"
autoload :CGI, "cgi"

class Chef
  class Provider

    
        def source_resource
          # It seems correct that this is a build_resource rather than declare_resource/DSL use since updating should not trigger a notification
          # unless the downloaded file is actually installed.  The case where the remote_file downloads the package but the package is already
          # installed on the target should not trigger a notification since the running state did not change.
          @source_resource ||= build_resource(:remote_file, default_download_cache_path) do
            source(new_resource.source)
            cookbook_name = new_resource.cookbook_name
            checksum(new_resource.checksum)
            backup(false)

            # since the source_resource can mutate here, we save off the @source_resource so we can inspect the actual state later
            if new_resource.remote_file_attributes
              new_resource.remote_file_attributes.each do |(k, v)|
                send(k.to_sym, v)
              end
            end
          end
        end