Sha256: 1e7eae778360da42096b2e2abdd0b9a301af03b9684776cdca671f00926cd321

Contents?: true

Size: 747 Bytes

Versions: 76

Compression:

Stored size: 747 Bytes

Contents

module TZInfo
  # Represents a timezone defined by a data source.
  class TimezoneInfo
    
    # The timezone identifier.
    attr_reader :identifier
    
    # Constructs a new TimezoneInfo with an identifier.
    def initialize(identifier)
      @identifier = identifier
    end
    
    # Returns internal object state as a programmer-readable string.
    def inspect
      "#<#{self.class}: #@identifier>"
    end
    
    # Constructs a Timezone instance for the timezone represented by this
    # TimezoneInfo.
    def create_timezone
      raise_not_implemented('create_timezone')
    end

    private

    def raise_not_implemented(method_name)
      raise NotImplementedError, "Subclasses must override #{method_name}"
    end
  end
end

Version data entries

76 entries across 72 versions & 27 rubygems

Version Path
ish_lib_manager-0.0.1 test/dummy/vendor/bundle/ruby/2.3.0/gems/tzinfo-1.2.2/lib/tzinfo/timezone_info.rb
angular-rails4-templates-0.4.1 vendor/ruby/2.1.0/gems/tzinfo-1.2.2/lib/tzinfo/timezone_info.rb
angular-rails4-templates-0.4.0 vendor/ruby/2.1.0/gems/tzinfo-1.2.2/lib/tzinfo/timezone_info.rb
tdiary-4.2.1 vendor/bundle/ruby/2.2.0/gems/tzinfo-1.2.2/lib/tzinfo/timezone_info.rb
tdiary-4.2.1 vendor/bundle/ruby/2.3.0/gems/tzinfo-1.2.2/lib/tzinfo/timezone_info.rb
angular-rails4-templates-0.3.0 vendor/ruby/2.1.0/gems/tzinfo-1.2.2/lib/tzinfo/timezone_info.rb
sc_core-0.0.7 test/dummy/vendor/bundle/ruby/2.2.0/gems/tzinfo-1.2.2/lib/tzinfo/timezone_info.rb
solidus_backend-1.0.0.pre3 vendor/bundle/gems/tzinfo-1.2.2/lib/tzinfo/timezone_info.rb
solidus_backend-1.0.0.pre2 vendor/bundle/gems/tzinfo-1.2.2/lib/tzinfo/timezone_info.rb
solidus_backend-1.0.0.pre vendor/bundle/gems/tzinfo-1.2.2/lib/tzinfo/timezone_info.rb
shoppe-paypal-1.1.0 vendor/bundle/ruby/2.1.0/gems/tzinfo-1.2.2/lib/tzinfo/timezone_info.rb
nanumfont-rails-0.1 vendor/bundle/ruby/2.1.0/gems/tzinfo-1.2.2/lib/tzinfo/timezone_info.rb
tzinfo-1.2.2 lib/tzinfo/timezone_info.rb
whos_dated_who-0.1.0 vendor/bundle/gems/tzinfo-1.2.1/lib/tzinfo/timezone_info.rb
whos_dated_who-0.0.1 vendor/bundle/gems/tzinfo-1.2.1/lib/tzinfo/timezone_info.rb
tzinfo-1.2.1 lib/tzinfo/timezone_info.rb