Sha256: ac35806bc8bbaa08d762ab61ffaa9f072d99a42456f2272070703183c0f474a2
Contents?: true
Size: 873 Bytes
Versions: 11
Compression:
Stored size: 873 Bytes
Contents
module MS class UserParam # (optional) a CV::Param object attr_accessor :unit # (required) attr_accessor :name # (optional) attr_accessor :value # (optional) e.g. 'xsd:float' attr_accessor :type # takes a few different incantations: # # name, unit_acc# or CV::Param object # name, value, unit_acc# or CV::Param object # name, value, type, unit_acc# or CV::Param object def initialize(*args) @unit = if args.size > 1 && ((args.last.is_a?(::CV::Param) || args.last =~ /^[A-Za-z]+:\d+$/)) unit_arg = args.pop unit_arg.is_a?(::CV::Param) ? unit_arg : MS::CV::Param[unit_arg] end @name, @value, @type = args end end end # A UserParam # (has no accession) # (has no cvRef) # name (required) # type # unitAccession # unitCvRef # unitName # value
Version data entries
11 entries across 11 versions & 1 rubygems