Module: Avm::Applications::Base::Publishing

Defined in:
lib/avm/applications/base/publishing.rb

Constant Summary collapse

PUBLISHABLE_KEY =
'publishable'

Instance Method Summary collapse

Instance Method Details

#publishable?Boolean

Returns:

  • (Boolean)


13
14
15
# File 'lib/avm/applications/base/publishing.rb', line 13

def publishable?
  publishable_value ? true : false
end

#stereotype_publishable?(stereotype) ⇒ Boolean

Returns:

  • (Boolean)


17
18
19
20
21
# File 'lib/avm/applications/base/publishing.rb', line 17

def stereotype_publishable?(stereotype)
  return publishable? unless publishable_value.is_a?(::Hash)

  parse_publishable_value(publishable_value[stereotype.stereotype_name], true)
end