OT style filtered the file.

git-svn-id: file:///srv/svn/repos/haiku/trunk/current@1462 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Ingo Weinhold 2002-10-08 21:51:16 +00:00
parent ea4148fa59
commit 6bfa67b39a
1 changed files with 51 additions and 47 deletions

View File

@ -1,29 +1,41 @@
/******************************************************************************
/
/ File: MessageRunner.h
/
/ Description:
/
/ Copyright 1998, Be Incorporated, All Rights Reserved.
/
*******************************************************************************/
//------------------------------------------------------------------------------
// Copyright (c) 2001-2002, OpenBeOS
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
//
// File Name: MessageRunner.h
// Author: Ingo Weinhold (bonefish@users.sf.net)
// Description: A BMessageRunner periodically sends a message to a
// specified target.
//------------------------------------------------------------------------------
#ifndef _MESSAGE_RUNNER_H
#define _MESSAGE_RUNNER_H
#include <BeBuild.h>
#include <Messenger.h>
/*----------------------------------------------------------------------*/
/*----- BMessageRunner class --------------------------------------------*/
class BMessageRunner {
public:
BMessageRunner(BMessenger target, const BMessage *msg,
BMessageRunner(BMessenger target, const BMessage *message,
bigtime_t interval, int32 count = -1);
BMessageRunner(BMessenger target, const BMessage *msg,
bigtime_t interval, int32 count, BMessenger reply_to);
virtual ~BMessageRunner();
BMessageRunner(BMessenger target, const BMessage *message,
bigtime_t interval, int32 count, BMessenger replyTo);
virtual ~BMessageRunner();
status_t InitCheck() const;
@ -31,32 +43,24 @@ virtual ~BMessageRunner();
status_t SetCount(int32 count);
status_t GetInfo(bigtime_t *interval, int32 *count) const;
/*----- Private or reserved -----------------------------------------*/
private:
virtual void _ReservedMessageRunner1();
virtual void _ReservedMessageRunner2();
virtual void _ReservedMessageRunner3();
virtual void _ReservedMessageRunner4();
virtual void _ReservedMessageRunner5();
virtual void _ReservedMessageRunner6();
virtual void _ReservedMessageRunner1();
virtual void _ReservedMessageRunner2();
virtual void _ReservedMessageRunner3();
virtual void _ReservedMessageRunner4();
virtual void _ReservedMessageRunner5();
virtual void _ReservedMessageRunner6();
BMessageRunner(const BMessageRunner &);
BMessageRunner &operator=(const BMessageRunner &);
void InitData(BMessenger target, const BMessage *msg,
bigtime_t interval, int32 count, BMessenger reply_to);
status_t SetParams(bool reset_i, bigtime_t interval,
bool reset_c, int32 count);
void InitData(BMessenger target, const BMessage *message,
bigtime_t interval, int32 count, BMessenger replyTo);
status_t SetParams(bool resetInterval, bigtime_t interval,
bool resetCount, int32 count);
int32 fToken;
uint32 _reserved[6];
};
/*-------------------------------------------------------------*/
/*-------------------------------------------------------------*/
#endif /* _MESSAGE_QUEUE_H */
#endif // _MESSAGE_RUNNER_H