50template <
typename Time = Types::time_type>
51class IHost :
public std::enable_shared_from_this<IHost<Time>> {
66 virtual size_t GetId()
const = 0;
191 const std::vector<uint8_t> &packet) = 0;
203 const std::vector<uint8_t> &packet) = 0;
233 return std::enable_shared_from_this<IHost<Time>>::shared_from_this();
virtual bool IsClassicalBitOnHost(size_t cbitId) const =0
Check if a classical bit is in the host.
virtual ~IHost()=default
The destructor.
virtual size_t GetStartQubitId() const =0
Get the id of the first qubit assigned to the host.
virtual bool SendPacketToHost(size_t hostId, const std::vector< uint8_t > &packet)=0
Send a packet to a host.
virtual std::vector< size_t > GetEntangledQubitMeasurementBitIds() const =0
Get the ids of the classical bits used for measurement of the qubits used for entanglement between ho...
virtual std::vector< size_t > GetNetworkEntangledQubitsIds() const =0
Get the ids of the qubits used for entanglement between hosts in the host.
virtual bool AreCbitsOnSameHost(size_t cbitId1, size_t cbitId2) const =0
Check if two classical bits are in the same host.
virtual bool RecvPacketFromHost(size_t hostId, const std::vector< uint8_t > &packet)=0
Receive a packet from a host.
std::shared_ptr< IHost< Time > > getptr()
Get a shared pointer to this object.
virtual std::vector< size_t > GetClassicalBitsIds() const =0
Get the ids of the classical bits in the host.
virtual size_t GetNumNetworkEntangledQubits() const =0
Get the number of network entangled qubits.
virtual size_t GetStartClassicalBitId() const =0
Get the id of the first classical bit assigned to the host.
virtual bool IsEntangledQubitOnHost(size_t qubitId) const =0
Check if a qubit used for entanglement between hosts is in the host.
virtual size_t GetNumClassicalBits() const =0
Get the number of classical bits.
virtual bool AreQubitsOnSameHost(size_t qubitId1, size_t qubitId2) const =0
Check if two qubits are in the same host.
virtual bool IsQubitOnHost(size_t qubitId) const =0
Check if a qubit is in the host.
virtual size_t GetNumQubits() const =0
Get the number of qubits.
virtual std::vector< size_t > GetQubitsIds() const =0
Get the ids of the qubits in the host.
virtual size_t GetId() const =0
Get the host id.