Initiating multiple slaves on one I2C bus

Hello!
I am working with the Mbed LPC1768 and I am trying to initialize 3 slaves on the same I2C bus. I can’t find information on how to exactly do this. I have seen things with pointers etc. But can’t i just implement this by using one bus and talk to each slave by sending the corresponding name address of the slave when writing on the bus? Like this:
In my main.cpp code I initialized a temperature sensor and an IO-expander with:

MCP9808 sensor(LPC_I2C_SDA, LPC_I2C_SCL, 0x30);  
PCA9534 hvControl(LPC_I2C_SDA, LPC_I2C_SCL);

then I have MCP9808.cpp:

MCP9808::MCP9808(PinName SDA_PIN, PinName SCL_PIN,addr) :
    bus(PinName SDA_PIN, PinName SCL_PIN), address1(addr) {}

...
bus.write(address1,...)

in “MCP9808.hpp” i Initialize the I2C bus

I2C bus

for IO expander “PCA9534.cpp”- (I repeat the same)

PCA9534::PCA9534(PinName SDA_PIN , PinName SCL_PIN) : bus(SDA_PIN, SCL_PIN){}
....

bus.write(addr2,....)

PCA9534.hpp:

I2C bus
bus.write(addr2,....)

Shall this work? I have seen other ways of doing it so i am a bit lost. Thanks!