Class: TiffFileTags::Tag

Inherits:
Object
  • Object
show all
Defined in:
lib/tags.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, id, type, map = nil) ⇒ Tag

Examples:

width = Tag.new(:width, 256, :uint)
metric = Tag.new(:photometric, 262, :ushort, {
  min_is_white: 0,
  min_is_black: 1
})


19
20
21
22
23
24
# File 'lib/tags.rb', line 19

def initialize(name, id, type, map = nil)
  @name = name
  @id = id
  @type = type
  @map = map
end

Instance Attribute Details

#idObject

Returns the value of attribute id.



5
6
7
# File 'lib/tags.rb', line 5

def id
  @id
end

#mapObject

Returns the value of attribute map.



7
8
9
# File 'lib/tags.rb', line 7

def map
  @map
end

#nameObject

Returns the value of attribute name.



4
5
6
# File 'lib/tags.rb', line 4

def name
  @name
end

#typeObject

Returns the value of attribute type.



6
7
8
# File 'lib/tags.rb', line 6

def type
  @type
end