File indexing completed on 2024-05-12 04:02:24
0001 /* -*- C++ -*- 0002 This file is part of ThreadWeaver. 0003 0004 SPDX-FileCopyrightText: 2005-2014 Mirko Boehm <mirko@kde.org> 0005 0006 SPDX-License-Identifier: LGPL-2.0-or-later 0007 */ 0008 0009 #ifndef PRIORITYDECORATOR_H 0010 #define PRIORITYDECORATOR_H 0011 0012 #include <ThreadWeaver/ThreadWeaver> 0013 0014 class PriorityDecorator : public ThreadWeaver::IdDecorator 0015 { 0016 public: 0017 explicit PriorityDecorator(int priority, ThreadWeaver::JobInterface *job, bool autoDelete = true); 0018 0019 // FIXME temp 0020 void run(ThreadWeaver::JobPointer self, ThreadWeaver::Thread *thread) override; 0021 0022 int priority() const override; 0023 0024 private: 0025 int m_priority; 0026 }; 0027 0028 #endif // PRIORITYDECORATOR_H