No, it can be both. I.e. multisensors or Qubino devices, which have both switch and sensors. If you're looking to make your own custom device, then it worth to have a look on Z-Uno device, it can be programmed your own way. And there are plenty of examples on developers page.