Sha256: a623d63f06c314a722812b84a9451d75ec12700581b70b5d284a60fdad4c7390

Contents?: true

Size: 509 Bytes

Versions: 6995

Compression:

Stored size: 509 Bytes

Contents

module CodeRay
module Encoders
  
  load :token_kind_filter
  
  # A simple Filter that removes all tokens of the :comment kind.
  # 
  # Alias: +remove_comments+
  # 
  # Usage:
  #  CodeRay.scan('print # foo', :ruby).comment_filter.text
  #  #-> "print "
  # 
  # See also: TokenKindFilter, LinesOfCode
  class CommentFilter < TokenKindFilter
    
    register_for :comment_filter
    
    DEFAULT_OPTIONS = superclass::DEFAULT_OPTIONS.merge \
      :exclude => [:comment, :docstring]
    
  end
  
end
end

Version data entries

6,995 entries across 6,982 versions & 75 rubygems

Version Path
coderay-1.1.3.rc1 lib/coderay/encoders/comment_filter.rb
logstash-output-scalyr-0.1.2 vendor/bundle/jruby/2.5.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
talon_one-2.0.0 vendor/bundle/ruby/2.3.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
talon_one-2.0.0 vendor/bundle/ruby/2.7.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
argon-1.3.1 vendor/bundle/ruby/2.7.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
symbolic_enum-1.1.5 vendor/bundle/ruby/2.7.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
honeybadger-4.5.3 vendor/bundle/ruby/2.6.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
chatops-rpc-0.0.2 fixtures/chatops-controller-example/vendor/bundle/ruby/2.5.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
chatops-rpc-0.0.1 fixtures/chatops-controller-example/vendor/bundle/ruby/2.5.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
dadapush_client-1.0.1 vendor/bundle/ruby/2.3.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
chess_engine-0.0.2 vendor/bundle/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
chess_engine-0.0.1 vendor/bundle/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
xaiml-0.1.3 vendor/bundle/ruby/2.5.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
alimentos-alu0100945645-0.1.0 vendor/bundle/ruby/2.3.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
alimentos-alu0100945645-1.0.0 vendor/bundle/ruby/2.3.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
xaiml-0.1.2 vendor/bundle/ruby/2.5.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
xaiml-0.1.1 vendor/bundle/ruby/2.5.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
xaiml-0.1.0 vendor/bundle/ruby/2.5.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
logstash-filter-device_detection-1.0.7-java vendor/bundle/jruby/1.9/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb
mrcooper-logstash-output-azuresearch-0.2.2 vendor/jruby/2.5.0/gems/coderay-1.1.2/lib/coderay/encoders/comment_filter.rb