Class: VectorSalad::StandardShapes::Pentagon

Inherits:
Polygon show all
Defined in:
lib/vector_salad/standard_shapes/pentagon.rb

Overview

Regular pentagon shape.

Instance Attribute Summary (collapse)

Instance Method Summary (collapse)

Constructor Details

- (Pentagon) initialize(radius, **options)

Create a regular pentagon.

Examples:

new(100)


11
12
13
# File 'lib/vector_salad/standard_shapes/pentagon.rb', line 11

def initialize(radius, **options)
  super(5, radius, **options)
end

Instance Attribute Details

- (Object) options Originally defined in class BasicShape

Returns the value of attribute options

- (Object) sides (readonly) Originally defined in class Polygon

Returns the value of attribute sides