Skip to content

Latest commit

 

History

History
93 lines (66 loc) · 1.88 KB

File metadata and controls

93 lines (66 loc) · 1.88 KB

description: Create a path from an object.

s2t.create_path

View source on GitHub

Create a path from an object.

s2t.create_path(
    path_source: s2t.Path
) -> s2t.Path

The BNF for a path is:

letter := [A-Za-z] digit := [0-9] <simple_step_char> := "_"|"-"| | letter | digit <simple_step> := <simple_step_char>+ := "(" (<simple_step> ".")* <simple_step> ")" := <simple_step> | := (( ".") * )?

Args

`path_source` a string or a Path object.

Returns

A Path.

Raises

`ValueError` if this is not a valid path.