Files
TaskExplorer/Queue.h
T
Patrick Wardle 205e24d309 version 2.0.0
-avoid UI calls when run in cmdline mode
 -hide icon when run in cmdline mode
 -option to scan single process
2018-12-21 20:19:09 -10:00

53 lines
1017 B
Objective-C

//
// Queue.h
// TaskExplorer
//
// Created by Patrick Wardle on 9/26/14.
// Copyright (c) 2014 Objective-See. All rights reserved.
//
//from: https://github.com/esromneb/ios-queue-object/blob/master/NSMutableArray%2BQueueAdditions.h
#import <Foundation/Foundation.h>
#import "NSMutableArray+QueueAdditions.h"
@interface Queue : NSObject
{
//the queue
NSMutableArray* eventQueue;
//queue processor thread
NSThread* qProcessorThread;
//condition for queue's status
NSCondition* queueCondition;
}
/* PROPERTIES */
//items in
@property NSUInteger itemsIn;
//items out
@property NSUInteger itemsOut;
//event queue
@property(retain, atomic)NSMutableArray* eventQueue;
//thread to process events
@property (nonatomic, retain)NSThread* qProcessorThread;
//condition for queue
@property (nonatomic, retain)NSCondition* queueCondition;
//METHODS
//add an object to the queue
-(void)enqueue:(id)anObject;
//process events from queue
-(void)processQueue:(id)threadParam;
@end