Class: SyntaxTree::CLI::STDINItem

Inherits:
Object
  • Object
show all
Defined in:
lib/syntax_tree/cli.rb

Overview

An item of work that correspond to the content passed in via stdin.

Instance Method Summary collapse

Instance Method Details

#filepathObject



88
89
90
# File 'lib/syntax_tree/cli.rb', line 88

def filepath
  :stdin
end

#handlerObject



84
85
86
# File 'lib/syntax_tree/cli.rb', line 84

def handler
  HANDLERS[".rb"]
end

#sourceObject



92
93
94
# File 'lib/syntax_tree/cli.rb', line 92

def source
  $stdin.read
end

#writable?Boolean

Returns:

  • (Boolean)


96
97
98
# File 'lib/syntax_tree/cli.rb', line 96

def writable?
  false
end