# `NebulaGraphEx.Types.Path`
[🔗](https://github.com/VChain/nebula_graph_ex/blob/v0.1.10/lib/nebula_graph_ex/types/path.ex#L1)

Represents a path through the graph — a sequence of alternating vertices
and edges, starting from a source vertex.

## Fields

* `:src` — source `%NebulaGraphEx.Types.Vertex{}`.
* `:steps` — list of step maps, each with:
  * `:dst` — `%NebulaGraphEx.Types.Vertex{}`
  * `:name` — edge type name binary
  * `:type` — integer edge type
  * `:ranking` — integer edge ranking
  * `:props` — map of edge property values

## Example

    %NebulaGraphEx.Types.Path{
      src: %Vertex{vid: "player100", tags: [...]},
      steps: [
        %{dst: %Vertex{vid: "player101", ...}, name: "follow", ranking: 0, props: %{}}
      ]
    }

# `step`

```elixir
@type step() :: %{
  dst: NebulaGraphEx.Types.Vertex.t(),
  name: String.t() | nil,
  type: integer(),
  ranking: integer(),
  props: %{required(String.t()) =&gt; term()}
}
```

# `t`

```elixir
@type t() :: %NebulaGraphEx.Types.Path{
  src: NebulaGraphEx.Types.Vertex.t(),
  steps: [step()]
}
```

# `length`

```elixir
@spec length(t()) :: non_neg_integer()
```

Returns the number of hops (edges) in the path.

# `vertices`

```elixir
@spec vertices(t()) :: [NebulaGraphEx.Types.Vertex.t()]
```

Returns an ordered list of all vertices in the path, starting with `:src`.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
