it is usual to have a solenoid valve in the liquid line prior to the expantion valve or regulator.
this shuts or opens as determined by the termostat in the space or the secondary refrigerant being cooled.
it may also be used to shut off various circuits in a cooler when the machine is operating on part-load conditions