Class: ServiceLookup
- Inherits:
-
Object
- Object
- ServiceLookup
- Defined in:
- lib/ims/lti/services/service_lookup.rb
Constant Summary collapse
- TOOL_SETTING_SERVICE =
ServiceDefinition.new( 'ToolSettingsContainer Service', %w(application/vnd.ims.lti.v2.toolsettings+json application/vnd.ims.lti.v2.toolsettings.simple+json), %w(LtiLink.custom.url ToolProxyBinding.custom.url ToolProxy.custom.url) )
- TOOL_CONSUMER_PROFILE_SERVICE =
ServiceDefinition.new( 'ToolConsumerProfile Service', %w(application/vnd.ims.lti.v2.toolconsumerprofile+json), [] )
- TOOL_PROXY_SERVICE =
ServiceDefinition.new( 'ToolProxy Service', %w(application/vnd.ims.lti.v2.toolproxy+json), [] )
Class Method Summary collapse
Class Method Details
.lookup(format) ⇒ Object
25 26 27 |
# File 'lib/ims/lti/services/service_lookup.rb', line 25 def self.lookup(format) services.select { |service| service.formats.include? format } end |
.services ⇒ Object
21 22 23 |
# File 'lib/ims/lti/services/service_lookup.rb', line 21 def self.services [TOOL_SETTING_SERVICE, TOOL_CONSUMER_PROFILE_SERVICE, TOOL_PROXY_SERVICE] end |