lib/perfect_shape/shape.rb in perfect-shape-0.0.10 vs lib/perfect_shape/shape.rb in perfect-shape-0.0.11

- old
+ new

@@ -18,11 +18,12 @@ # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. module PerfectShape - # Superclass of all shapes + # Superclass of all shapes. Not meant to be used directly. + # Subclasses must implement/override methods as needed. class Shape # Subclasses must implement def min_x end @@ -79,8 +80,12 @@ x = x_or_point x, y = x if y.nil? && x_or_point.is_a?(Array) && x_or_point.size == 2 x = BigDecimal(x.to_s) y = BigDecimal(y.to_s) [x, y] + end + + # Subclasses must implement + def ==(other) end end end