Yurttas/PL/SL/ruby/F/02/08/01/B.rb

Revision as of 23:57, 7 November 2013 by MassBot1 (talk | contribs) (Created page with "<syntaxhighlight lang="ruby" line start="1" enclose="div"># # Copyright(C) 2008 # All Rights Reserved. Salih Yurttas, ZCubes, BitsOfCode Software Systems, Inc.. # # Permiss...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
 1#
 2#  Copyright(C) 2008
 3#  All Rights Reserved. Salih Yurttas, ZCubes, BitsOfCode Software Systems, Inc..
 4#
 5#  Permission to use, copy, modify, and distribute this
 6#  software and its documentation for EDUCATIONAL purposes
 7#  and without fee is hereby granted provided that this
 8#  copyright notice appears in all copies.
 9#
10#  date   : January 1, 2008.
11#  author : Salih Yurttas.
12#
13#  B.rb
14#
15
16
17class B
18  def initialize(i1,i2)
19    @i1, @i2 = i1, i2
20  end
21
22  def i1        # accessor(getter) for i1
23    @i1
24  end
25
26  def i1=(i1)   # mutator(setter) for i1
27    @i1 = i1
28  end
29
30  def i2        # accessor(getter) for i2
31    @i2
32  end
33
34  def i2=(i2)   # mutator(setter) for i2
35    @i2 = i2
36  end
37end