Files
CxIDE/Core/SwiftEngineWrapper.h
T
cx-git-agent c118996746 feat: CxIDE v1 — native macOS SwiftUI IDE with agentic AI assistant
- SwiftUI macOS app with C++17 code analysis engine (ObjC++ bridge)
- Agentic AI loop: LLM plans → tool calls → execution → feedback loop
- 15 agent tools: file ops, terminal, git, xcode build, code intel
- 7 persistent terminal tools with background session management
- Chat sidebar with agent step rendering and auto-apply
- NVIDIA NIM API integration (Llama 3.3 70B default)
- OpenAI tool_calls format with prompt-based fallback
- Code editor with syntax highlighting and multi-tab support
- File tree, console view, terminal view
- Git integration and workspace management
2026-04-21 16:05:52 -05:00

57 lines
3.0 KiB
Objective-C

#import <Foundation/Foundation.h>
NS_ASSUME_NONNULL_BEGIN
@interface SwiftEngineWrapper : NSObject
// ─── Configuration ───────────────────────────────────────────────
- (void)setMaxLineLength:(NSInteger)length;
- (void)setMaxNestingDepth:(NSInteger)depth;
- (void)setMaxFunctionLength:(NSInteger)length;
- (void)setMinCommentRatio:(double)ratio;
- (void)setDetectForceUnwraps:(BOOL)enabled;
- (void)setDetectForceTry:(BOOL)enabled;
- (void)setDetectForceCast:(BOOL)enabled;
- (void)setDetectDuplicateLines:(BOOL)enabled;
- (void)setDetectTodoFixme:(BOOL)enabled;
- (void)setDetectRetainCycles:(BOOL)enabled;
// ─── Full Analysis ───────────────────────────────────────────────
- (NSString *)runAnalysis:(NSString *)code;
- (NSDictionary<NSString *, id> *)runStructuredAnalysis:(NSString *)code;
// ─── Counting ────────────────────────────────────────────────────
- (NSInteger)getChecksum:(NSString *)code;
- (NSInteger)countLines:(NSString *)code;
- (NSInteger)countBlankLines:(NSString *)code;
- (NSInteger)countCodeLines:(NSString *)code;
- (NSInteger)countFunctions:(NSString *)code;
- (NSInteger)countClasses:(NSString *)code;
- (NSInteger)countStructs:(NSString *)code;
- (NSInteger)countEnums:(NSString *)code;
- (NSInteger)countProtocols:(NSString *)code;
- (NSInteger)countPattern:(NSString *)code pattern:(NSString *)pattern;
// ─── Analysis ────────────────────────────────────────────────────
- (NSString *)estimateComplexity:(NSString *)code;
- (NSInteger)cyclomaticComplexity:(NSString *)code;
- (double)maintainabilityIndex:(NSString *)code;
- (BOOL)checkBalancedBraces:(NSString *)code;
- (NSArray<NSString *> *)extractKeywords:(NSString *)code;
- (NSArray<NSString *> *)findIssues:(NSString *)code;
- (double)commentRatio:(NSString *)code;
// ─── Symbol & Import Extraction ──────────────────────────────────
- (NSArray<NSDictionary<NSString *, id> *> *)extractSymbols:(NSString *)code;
- (NSArray<NSString *> *)extractImports:(NSString *)code;
// ─── Duplicate & TODO Detection ──────────────────────────────────
- (NSArray<NSDictionary<NSString *, NSNumber *> *> *)detectDuplicateLines:(NSString *)code;
- (NSArray<NSDictionary<NSString *, id> *> *)extractTodoComments:(NSString *)code;
// ─── Indentation ────────────────────────────────────────────────
- (NSInteger)suggestIndentation:(NSString *)codeBefore tabWidth:(NSInteger)tabWidth;
@end
NS_ASSUME_NONNULL_END