class SourceMap::Parser
- SourceMap::Parser
- Reference
- Object
Included Modules
- JSON::Serializable
Defined in:
sourcemap_parser/source_map.crConstructors
- .new(version : Int32, sources : Array(String), names : Array(String), file : String, mappings : String)
- .new(pull : JSON::PullParser)
Class Method Summary
Instance Method Summary
- #after_initialize
- #file : String
-
#mapping_for(generated_line : Int32, generated_column : Int32) : Mapping | Nil
Retrieve a Mapping for a specific line and column in the generated code
- #mapping_with_less_column_for(generated_line : Int32, generated_column : Int32 | Nil, start_column : Int32 = 1) : Mapping | Nil
-
#mapping_with_source_path_for(generated_line : Int32, generated_column : Int32) : Mapping | Nil
Retrieve a mapping for a specific line in the generated code and with source_path
- #mappings : String
-
#mappings_for_source(source_path : String) : Array(Mapping)
Retrieve all mappings for a specific source path
- #names : Array(String)
- #parse_mapping(segment, line_num) : Mapping
- #parse_mappings(string) : Array(Mapping)
- #parsed_mappings : Array(Mapping)
- #previous : Hash(String, Int32)
- #previous=(previous : Hash(String, Int32))
- #sourcemap_uri : URI
- #sourcemap_uri=(sourcemap_uri : URI)
- #sources : Array(String)
- #sources_content : Array(String)
- #undiff(int, type)
- #version : Int32
Constructor Detail
def self.new(version : Int32, sources : Array(String), names : Array(String), file : String, mappings : String)
#
Class Method Detail
Instance Method Detail
Retrieve a Mapping for a specific line and column in the generated code
def mapping_with_less_column_for(generated_line : Int32, generated_column : Int32 | Nil, start_column : Int32 = 1) : Mapping | Nil
#
def mapping_with_source_path_for(generated_line : Int32, generated_column : Int32) : Mapping | Nil
#
Retrieve a mapping for a specific line in the generated code and with source_path
Retrieve all mappings for a specific source path