| OLD | NEW |
| 1 // Copyright (c) 2009-2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009-2010 The Chromium OS Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef LOGIN_MANAGER_CHILD_JOB_H_ | 5 #ifndef LOGIN_MANAGER_CHILD_JOB_H_ |
| 6 #define LOGIN_MANAGER_CHILD_JOB_H_ | 6 #define LOGIN_MANAGER_CHILD_JOB_H_ |
| 7 | 7 |
| 8 #include <gtest/gtest.h> | 8 #include <gtest/gtest.h> |
| 9 #include <time.h> | 9 #include <time.h> |
| 10 #include <unistd.h> | 10 #include <unistd.h> |
| 11 | 11 |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 66 static const int kBWSI; | 66 static const int kBWSI; |
| 67 | 67 |
| 68 }; | 68 }; |
| 69 | 69 |
| 70 | 70 |
| 71 class ChildJob : public ChildJobInterface { | 71 class ChildJob : public ChildJobInterface { |
| 72 public: | 72 public: |
| 73 explicit ChildJob(const std::vector<std::string>& arguments); | 73 explicit ChildJob(const std::vector<std::string>& arguments); |
| 74 virtual ~ChildJob(); | 74 virtual ~ChildJob(); |
| 75 | 75 |
| 76 // Overridden from ChildJob | 76 // Overridden from ChildJobInterface |
| 77 virtual bool ShouldStop() const; | 77 virtual bool ShouldStop() const; |
| 78 virtual void RecordTime(); | 78 virtual void RecordTime(); |
| 79 virtual void Run(); | 79 virtual void Run(); |
| 80 virtual void StartSession(const std::string& email); | 80 virtual void StartSession(const std::string& email); |
| 81 virtual void StopSession(); | 81 virtual void StopSession(); |
| 82 virtual uid_t GetDesiredUid() const; | 82 virtual uid_t GetDesiredUid() const; |
| 83 virtual void SetDesiredUid(uid_t uid); | 83 virtual void SetDesiredUid(uid_t uid); |
| 84 virtual bool IsDesiredUidSet() const; | 84 virtual bool IsDesiredUidSet() const; |
| 85 virtual const std::string GetName() const; | 85 virtual const std::string GetName() const; |
| 86 virtual void SetArguments(const std::string& arguments); | 86 virtual void SetArguments(const std::string& arguments); |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 130 FRIEND_TEST(ChildJobTest, ShouldNotStopTest); | 130 FRIEND_TEST(ChildJobTest, ShouldNotStopTest); |
| 131 FRIEND_TEST(ChildJobTest, StartStopSessionTest); | 131 FRIEND_TEST(ChildJobTest, StartStopSessionTest); |
| 132 FRIEND_TEST(ChildJobTest, StartStopSessionFromLoginTest); | 132 FRIEND_TEST(ChildJobTest, StartStopSessionFromLoginTest); |
| 133 FRIEND_TEST(ChildJobTest, SetArguments); | 133 FRIEND_TEST(ChildJobTest, SetArguments); |
| 134 DISALLOW_COPY_AND_ASSIGN(ChildJob); | 134 DISALLOW_COPY_AND_ASSIGN(ChildJob); |
| 135 }; | 135 }; |
| 136 | 136 |
| 137 } // namespace login_manager | 137 } // namespace login_manager |
| 138 | 138 |
| 139 #endif // LOGIN_MANAGER_CHILD_JOB_H_ | 139 #endif // LOGIN_MANAGER_CHILD_JOB_H_ |
| 140 | |
| OLD | NEW |