28 lines
682 B
Objective-C
28 lines
682 B
Objective-C
#ifndef MMNetworkSocketsProvider_h
|
|
#define MMNetworkSocketsProvider_h
|
|
|
|
#import <Foundation/Foundation.h>
|
|
#import "MMTelemetryProvider.h"
|
|
|
|
NS_ASSUME_NONNULL_BEGIN
|
|
|
|
/**
|
|
* MMNetworkSocketsProvider
|
|
* Inspects system-wide open TCP and UDP sockets, local/remote endpoints, connection states,
|
|
* and owning processes.
|
|
*/
|
|
@interface MMNetworkSocketsProvider : NSObject <MMTelemetryProvider>
|
|
|
|
- (instancetype)init;
|
|
|
|
/**
|
|
* Pure calculator / summarizer method for deterministic unit testing.
|
|
*/
|
|
+ (NSDictionary<NSString *, id> *)calculateSocketSummaryWithSocketList:(NSArray<NSDictionary<NSString *, id> *> *)sockets;
|
|
|
|
@end
|
|
|
|
NS_ASSUME_NONNULL_END
|
|
|
|
#endif /* MMNetworkSocketsProvider_h */
|