module OpenComponents
Public
↑ topConstants
- DEFAULT_REGISTRY
Default OC registry URL (localhost:3030).
- DEFAULT_TIMEOUT
Default request timeout in seconds (5)
Public Class Methods
config()
click to toggle source
Getter for OC Configuration
.
Returns¶ ↑
Returns the Configuration
if set, a default Configuration
if not set.
# File lib/opencomponents.rb, line 38 def self.config @@_config ||= Configuration.new(DEFAULT_REGISTRY, DEFAULT_TIMEOUT) end
configure() { |config| ... }
click to toggle source
Setter for Configuration
.
Examples¶ ↑
OpenComponents.configure do |oc| oc.registry = 'http://my-awesome-oc-registry.com' end
Returns¶ ↑
Returns the Configuration
.
# File lib/opencomponents.rb, line 51 def self.configure yield self.config end
Internal
↑ topConstants
- ComponentNotFound
Custom exception class to raise in the event a component cannot be found in the registry.
- Configuration
Stores configuration data.
- registry
-
String for the registry host.
- RegistryTimeout
Custom exception class to raise for response timeouts.
- Template
Wrapper object for unrendered OC templates.
- src
-
String for the template URL.
- type
-
String for template engine type.
- key
-
String for template key.