Some time ago, I was thinking about whether it would be possible to generalize some results from functional analysis on Banach spaces to some metric spaces. Specifically, I wondered whether if one were to assume that the metric space possesses some parametrized segment-like structure (which, for example, in Banach spaces would consist of functions of the form $[0,1] \ni t \mapsto (1-t)x + ty$, where $x, y$ are elements of some Banach space), we could define something analogous to continuous linear (or, more appropriately, affine) operators by requiring that such operator would "preserve" this structure.
I'd like to ask if there are any papers or books which might be related to this topic and, if so, where should I look for them.