Module: DList
- Defined in:
- lib/dblista.rb,
lib/dblista/info.rb,
lib/dblista/stats.rb,
lib/dblista/version.rb,
lib/dblista/constants.rb
Overview
Main module
Defined Under Namespace
Modules: CardStyle, Errors, Helpers, Information, Libraries, List, Permissions, Tags, User Classes: Error, Stats
Constant Summary collapse
- API_PATH =
API path prefix
'https://api.dlist.top/v1'
- IS_NUMBER =
Regexp for checking if string is a number
/^\d+$/.freeze
- Cache =
Cache
Zache.new
- CACHE_LIFETIME =
Cache entry lifetime
15
- VERSION =
Wrapper version
'0.7.1'
Class Method Summary collapse
Class Method Details
._cache(name) ⇒ Object
94 95 96 |
# File 'lib/dblista.rb', line 94 def self._cache(name) DList::Cache.get(name.to_sym, lifetime: DList::CACHE_LIFETIME) { yield } end |
._https(uri) ⇒ Object
33 34 35 36 37 |
# File 'lib/dblista.rb', line 33 def self._https(uri) Net::HTTP.new(uri.host, uri.port).tap do |http| http.use_ssl = true end end |