net.minecraft.block.dispenser.EquippableDispenserBehavior has a static method dispense(BlockPointer, ItemStack) that returns a boolean
EquippableDispenserBehavior extends ItemDispenserBehavior which has a non static method dispense(BlockPointer, ItemStack) that returns an ItemStack
you can use both methods
EquippableDispenserBehavior.dispense(...) -> static one
((ItemDispenserBehavior) equippableDispenserBehavior).dispense(...) -> non static one
but... it's a bit weird that you have to cast to a superclass just to use the method
I think the static method in EquippableDispenserBehavior should be renamed