/* * IXConnectionState.h * Author: Benjamin Sergeant * Copyright (c) 2019 Machine Zone, Inc. All rights reserved. */ #pragma once #include #include #include #include namespace ix { class ConnectionState { public: ConnectionState(); virtual ~ConnectionState() = default; virtual void computeId(); virtual const std::string& getId() const; void setTerminated(); bool isTerminated() const; static std::shared_ptr createConnectionState(); protected: std::atomic _terminated; std::string _id; static std::atomic _globalId; }; }