(value any)
| 328 | } |
| 329 | |
| 330 | func (a *networkAdapter) NativeToValue(value any) ref.Val { |
| 331 | switch v := value.(type) { |
| 332 | case netip.Addr: |
| 333 | return IP{Addr: v} |
| 334 | case netip.Prefix: |
| 335 | return CIDR{Prefix: v} |
| 336 | } |
| 337 | // Delegate to the wrapped adapter (e.g., Protobuf adapter) |
| 338 | return a.Adapter.NativeToValue(value) |
| 339 | } |
| 340 | |
| 341 | // --- Implementation Logic --- |
| 342 |
nothing calls this directly
no test coverage detected