diff options
| author | Jan-Hendrik Hühne <[email protected]> | 2012-06-06 15:50:40 +0200 |
|---|---|---|
| committer | Jan-Hendrik Hühne <[email protected]> | 2012-06-06 15:50:40 +0200 |
| commit | a751bf1f34852531caf0b5f80152e44fff020dd4 (patch) | |
| tree | 16ced2090d9bb582c295def740070db9dc2f6c92 /lib/axlsx/util/validators.rb | |
| parent | ac94d6ff30467bdfdfb182bf2f8fcd945fbd748a (diff) | |
| download | caxlsx-a751bf1f34852531caf0b5f80152e44fff020dd4.tar.gz caxlsx-a751bf1f34852531caf0b5f80152e44fff020dd4.zip | |
New validators and tests.
Diffstat (limited to 'lib/axlsx/util/validators.rb')
| -rw-r--r-- | lib/axlsx/util/validators.rb | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/lib/axlsx/util/validators.rb b/lib/axlsx/util/validators.rb index c7c97e78..f76c57ba 100644 --- a/lib/axlsx/util/validators.rb +++ b/lib/axlsx/util/validators.rb @@ -248,4 +248,18 @@ module Axlsx def self.validate_sheet_view_type(v) RestrictionValidator.validate :sheet_view_type, [:normal, :page_break_preview, :page_layout], v end + + # Requires that the value is a valid active pane type. + # valid types must be one of bottom_left, bottom_right, top_left, top_right + # @param [Any] v The value validated + def self.validate_active_pane_type(v) + RestrictionValidator.validate :active_pane_type, [:bottom_left, :bottom_right, :top_left, :top_right], v + end + + # Requires that the value is a valid split state type. + # valid types must be one of frozen, frozen_split, split + # @param [Any] v The value validated + def self.validate_split_state_type(v) + RestrictionValidator.validate :split_state_type, [:frozen, :frozen_split, :split], v + end end
\ No newline at end of file |
