Sha256: 9f7a765009e1d4f777b747ac6e8ab48aef1c44e951953af5a2f9cad85e7669a6
Contents?: true
Size: 631 Bytes
Versions: 4
Compression:
Stored size: 631 Bytes
Contents
require 'securerandom' module BjondApi class BjondAppDefinition attr_accessor :id, :author, :name, :description, :rootEndpoint, :configURL, :iconURL, :rootEndpoint, :integrationEvent, :integrationConsequence def initialize() self.id = SecureRandom.uuid self.configURL = "http://#{self.get_hostname}/bjond-app/services" self.rootEndpoint = "http://#{self.get_hostname}/bjond-app/services" end def get_hostname() Rails.application.config.action_controller.default_url_options ? Rails.application.config.action_controller.default_url_options[:host] : nil || `hostname` end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
bjond-api-0.1.4 | lib/bjond-app-definition.rb |
bjond-api-0.1.3 | lib/bjond-app-definition.rb |
bjond-api-0.1.2 | lib/bjond-app-definition.rb |
bjond-api-0.1.1 | lib/bjond-app-definition.rb |