summaryrefslogtreecommitdiffhomepage
path: root/lib/axlsx/workbook/worksheet/worksheet_hyperlink.rb
diff options
context:
space:
mode:
authorRandy Morgan <[email protected]>2012-10-14 13:20:29 +0900
committerRandy Morgan <[email protected]>2012-10-14 13:20:29 +0900
commit25ebea9143c136999bdaeb372fb26d2c070ca730 (patch)
tree0916e207715d821d3f4f8de45c9690ca65272633 /lib/axlsx/workbook/worksheet/worksheet_hyperlink.rb
parent93b70a39999ac4d06e43e495f3fd283e9630d9d2 (diff)
downloadcaxlsx-25ebea9143c136999bdaeb372fb26d2c070ca730.tar.gz
caxlsx-25ebea9143c136999bdaeb372fb26d2c070ca730.zip
Refactored to use options parser, accessors and serialization attributes
Diffstat (limited to 'lib/axlsx/workbook/worksheet/worksheet_hyperlink.rb')
-rw-r--r--lib/axlsx/workbook/worksheet/worksheet_hyperlink.rb6
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/axlsx/workbook/worksheet/worksheet_hyperlink.rb b/lib/axlsx/workbook/worksheet/worksheet_hyperlink.rb
index 4807d58d..830698cc 100644
--- a/lib/axlsx/workbook/worksheet/worksheet_hyperlink.rb
+++ b/lib/axlsx/workbook/worksheet/worksheet_hyperlink.rb
@@ -3,7 +3,7 @@ module Axlsx
# A worksheet hyperlink object. Note that this is not the same as a drawing hyperlink object.
class WorksheetHyperlink
-
+ include Axlsx::OptionsParser
include Axlsx::Accessors
include Axlsx::SerializedAttributes
# Creates a new hyperlink object.
@@ -19,9 +19,7 @@ module Axlsx
DataTypeValidator.validate "Hyperlink.worksheet", [Worksheet], worksheet
@worksheet = worksheet
@target = :external
- options.each do |o|
- self.send("#{o[0]}=", o[1]) if self.respond_to? "#{o[0]}="
- end
+ parse_options options
yield self if block_given?
end