Module: Jinx::IdAlias
- Defined in:
- lib/jinx/metadata/id_alias.rb
Overview
Mix-in for Java classes which have an id
attribute. Since id
is a reserved Ruby method, this mix-in defines an identifier
attribute which fronts the id
attribute. This mix-in should be included by any JRuby wrapper class for a Java class or interface which implements an id
property.
Instance Method Summary collapse
-
#identifier ⇒ Integer
Returns the identifier.
-
#identifier=(value) ⇒ Object
Sets the identifier to the given value.
Instance Method Details
#identifier ⇒ Integer
Returns the identifier. This method delegates to the Java id
attribute reader method.
11 12 13 |
# File 'lib/jinx/metadata/id_alias.rb', line 11 def identifier getId end |
#identifier=(value) ⇒ Object
Sets the identifier to the given value. This method delegates to the Java id
attribute writer method.
20 21 22 |
# File 'lib/jinx/metadata/id_alias.rb', line 20 def identifier=(value) setId(value) end |