SystemVerilog allows to have constraints between variables of different objects. These are called global constraints. Using the hierarchy notation, constraints can be applied on variables of different objects. When object is randomized, so are the contained objects and all other constraints are considered simultaneously.