Class: RDF::Literal::Short

Inherits:
Int show all
Defined in:
vendor/bundler/ruby/2.5.0/bundler/gems/rdf-xsd-e532a0ab7189/lib/rdf/xsd/integer.rb

Overview

short is derived from int by setting the value of maxInclusive to be 32767 and minInclusive to be -32768. The base type of short is int.

Direct Known Subclasses

Byte

Constant Summary collapse

DATATYPE =
RDF::XSD.short

Instance Method Summary collapse

Methods inherited from Integer

#to_sxp

Instance Method Details

#valid?Boolean

Returns:

  • (Boolean)


90
91
92
# File 'vendor/bundler/ruby/2.5.0/bundler/gems/rdf-xsd-e532a0ab7189/lib/rdf/xsd/integer.rb', line 90

def valid?
  super && @object >= -32768 && @object <= 32767
end