Class: When::RS::Identifier

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

Overview

参照系の識別子

see gml schema

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, version = nil, remarks = nil) ⇒ Identifier

オブジェクトの生成

Parameters:



588
589
590
591
592
# File 'lib/when_exe/basictypes.rb', line 588

def initialize(name, version=nil, remarks=nil)
  @name    = name
  @version = version
  @remarks = remarks
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(name, *args, &block) ⇒ Object

Note:

When::RS::Identifier で定義されていないメソッドは 処理を @name (type: When::BasicTypes::Code) に委譲する

その他のメソッド



599
600
601
602
603
604
605
606
# File 'lib/when_exe/basictypes.rb', line 599

def method_missing(name, *args, &block)
  self.class.module_eval %Q{
    def #{name}(*args, &block)
      @name.send("#{name}", *args, &block)
    end
  } unless When::Parts::MethodCash.escape(name)
  @name.send(name, *args, &block)
end

Instance Attribute Details

#nameWhen::BasicTypes::Code (readonly)

The code or name for this Identifier



568
569
570
# File 'lib/when_exe/basictypes.rb', line 568

def name
  @name
end

#remarksArray<String> (readonly)

Remarks about this code or alias

Returns:

  • (Array<String>)

    String は URI/IRI文字列の場合あり



580
581
582
# File 'lib/when_exe/basictypes.rb', line 580

def remarks
  @remarks
end

#versionArray<String> (readonly)

Identifier of the version of the associated codeSpace or code

Returns:



574
575
576
# File 'lib/when_exe/basictypes.rb', line 574

def version
  @version
end