class ConfigNodeComment

Public Class Methods

new(comment) click to toggle source
Calls superclass method Hocon::Impl::ConfigNodeSingleToken::new
# File lib/hocon/impl/config_node_comment.rb, line 9
def initialize(comment)
  super(comment)
  unless Hocon::Impl::Tokens.comment?(@token)
    raise Hocon::ConfigError::ConfigBugOrBrokenError, 'Tried to create a ConfigNodeComment from a non-comment token'
  end
end

Public Instance Methods

comment_text() click to toggle source
# File lib/hocon/impl/config_node_comment.rb, line 16
def comment_text
  Hocon::Impl::Tokens.comment_text(@token)
end