Sha256: 7361b3d25ce3044052eeae5631f2f56fd8b19d31abdb4007272817942ad1c3c0

Contents?: true

Size: 497 Bytes

Versions: 1

Compression:

Stored size: 497 Bytes

Contents

module OpenAssets
  module Protocol

    class AssetDefinitionLoader

      attr_reader :loader

      def initialize(metadata)
        if metadata.start_with?('http://') || metadata.start_with?('https://')
          @loader = HttpAssetDefinitionLoader.new(metadata)
        end
      end

      # load Asset Definition File
      # @return[OpenAssets::Protocol::AssetDefinition] loaded asset definition object
      def load_definition
        @loader.load if @loader
      end

    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
openassets-ruby-0.5.4 lib/openassets/protocol/asset_definition_loader.rb