Sha256: 059527654a835633e95965a80dc66022acd9335e99cdf402005292c18ff866e5
Contents?: true
Size: 341 Bytes
Versions: 3
Compression:
Stored size: 341 Bytes
Contents
# frozen_string_literal: true module Grumlin class Vertex attr_reader :label, :id def initialize(label:, id:) @label = label @id = Typing.cast(id) end def ==(other) @label == other.label && @id == other.id end def inspect "<V #{@label}(#{@id})>" end alias to_s inspect end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
grumlin-0.1.3 | lib/grumlin/vertex.rb |
grumlin-0.1.1 | lib/grumlin/vertex.rb |
grumlin-0.1.0 | lib/grumlin/vertex.rb |