and to allocate longer data? does it map like an analog var?
At the program level, you can create SIGNAL variables of any length between 1 bit (BOOL type) to 32bit (signed INT), and use those variables accordingly. For example, if you have SIGNAL MyOut1 $OUT[1] TO $OUT[8], and then execute MyOut1=128, $OUT[8] will be True and $OUTs 1-7 will be False.
Multi-bit $INs can be used the same way. However, KSS does not implicitly do the sign bit unless the SIGNAL is a full 32bit in size.
Analogs are different -- they have to be configured in IOSYS.INI, and that varies quite a bit depending on the specifics of the analog I/O module you're using. But it's still passing data over $OUTs and $INs -- in fact, it's entirely possible to use a binary "word" for analog data, you just have to do the math.
the big block of I/Os seems like an easy way to work with the bridge but how can i identify wich gateway works like that?
That's going to require going to the Bridge manufacturer's web site and digging into their technical documentation. AnyBus is usually pretty good, but I have run into issues in the past when I assumed they would "just work" without doing some configuration myself. For example, the AnyBus Devicenet/EthernetIP bridge required Allen-Braley RSLogix software to configure the EIP side, even though the DeviceNet side was utterly simple.
But in this case, is it possible to use the gateway to take it from Modbus TCP? I imagine I have to configure an output in the gateway that goes to a PC address to catch it.
I haven't used a bridge with ModBus, so I can't say. But probably you would need to get the correct configuration software from the Bridge manufacturer (which may be free, may cost extra) in order to configure it.