Merge pull request #10 from gunyarakun/fix-invalid-return
[cocotron.git] / Foundation / NSSpellEngine.h
bloba9c96ff8c7165a748b85018b9bf7ed048af93d78
1 //
2 // NSSpellEngine.h
3 // Foundation
4 //
5 // Created by Christopher Lloyd on 8/23/11.
6 // Copyright 2011 __MyCompanyName__. All rights reserved.
7 //
9 #import <Foundation/NSObject.h>
10 #import <Foundation/NSSpellServer.h>
12 /* Private class which implements the delegate behavior of NSSpellServer directly, used for in-process spell checking. */
14 @interface NSSpellEngine : NSObject <NSSpellServerDelegate>
16 + (NSArray *)allSpellEngines;
17 + (NSArray *)spellEngines;
19 - (NSString *)vendor;
20 - (NSArray *)languages;
22 - (NSRange)checkGrammarInString:(NSString *)string language:(NSString *)language details:(NSArray **)outDetails;
24 - (NSArray *)checkString:(NSString *)stringToCheck offset:(NSUInteger)offset types:(NSTextCheckingTypes)checkingTypes options:(NSDictionary *)options orthography:(NSOrthography *)orthography wordCount:(NSInteger *)wordCount;
26 - (void)didForgetWord:(NSString *)word inLanguage:(NSString *)language;
28 - (void)didLearnWord:(NSString *)word inLanguage:(NSString *)language;
30 - (NSRange)findMisspelledWordInString:(NSString *)stringToCheck language:(NSString *)language wordCount:(NSInteger *)wordCount countOnly:(BOOL)countOnly;
32 - (NSArray *)suggestCompletionsForPartialWordRange:(NSRange)range inString:(NSString *)string language:(NSString *)language;
34 - (NSArray *)suggestGuessesForWord:(NSString *)word inLanguage:(NSString *)language;
36 @end