That's a great analogy, actually! The components of a hydraulic ram line up perfectly with a boost converter -- there's an inductor (the inertia of moving water), a switch (the waste valve), a diode (the check valve), and a capacitor (the pressure vessel).