class Ruby::Prism::Relocation::Source

Represents the source of a repository that will be reparsed.

Attributes

The value that will need to be reparsed.

Public Class Methods

Initialize the source with the given value.

: (untyped value) -> void

# File lib/ruby/prism/relocation.rb, line 232
def initialize(value)
  @value = value
end

Public Instance Methods

Create a code units cache for the given encoding.

: (Encoding encoding) -> _CodeUnitsCache

# File lib/ruby/prism/relocation.rb, line 246
def code_units_cache(encoding)
  result.code_units_cache(encoding)
end

Reparse the value and return the parse result.

: () -> ParseResult

# File lib/ruby/prism/relocation.rb, line 239
def result
  raise NotImplementedError, "Subclasses must implement #result"
end