| Inherits from | NSObject |
| Declared in | GBCommentsProcessor.h<br />GBCommentsProcessor.m |
Implements comments processing.
The main responsibility of this class is to process comments. As it's a helper class for GBProcessor , it's processing is driven by the processor, so there's no need to create instances elsewhere.
+ processorWithSettingsProvider:
Returns autoreleased processor to work with the given GBApplicationSettingsProvider implementor.
- initWithSettingsProvider:
Initializes the processor to work with the given GBApplicationSettingsProvider implementor.
- processComment:withContext:store:
Processes the given GBComment using the given context and store.
- processComment:withStore:
Processes the given GBComment using the given store.
- registerParagraphItemFromString:toParagraph:
- registerArgumentsFromString:
- namedArgumentFromString:usingRegex:matchLength:
- simpleArgumentFromString:usingRegex:matchLength:
- linkArgumentFromString:usingRegex:matchLength:
- registerListFromString:toParagraph:
- flattenedListItemsFromString:
- regexMatchingFirstListItemInString:matchedRange:ordered:
- registerWarningFromString:toParagraph:
- registerBugFromString:toParagraph:
- registerExampleFromString:toParagraph:
- registerSpecialFromString:type:usingRegex:toParagraph:
- registerTextFromString:toParagraph:
- linkifiedParagraphItemsFromItem:
- paragraphSimpleLinkItemsFromString:
- paragraphTextItemsFromString:
- wordifiedTextFromString:
- trimmedTextFromString:
- remoteMemberLinkItemFromString:matchRange:
- simpleLinkItemFromString:matchRange:
- componentsSeparatedByEmptyLinesFromString:
- componentsSeparatedByNewLinesFromString:
Returns autoreleased processor to work with the given GBApplicationSettingsProvider implementor.
+ (id)processorWithSettingsProvider:(id)settingsProvider Returns initialized instance or nil if initialization fails.
Returns autoreleased processor to work with the given GBApplicationSettingsProvider implementor.
This is the designated initializer.
nil . GBCommentsProcessor.hGBCommentsProcessor.m Initializes the processor to work with the given GBApplicationSettingsProvider implementor.
- (id)initWithSettingsProvider:(id)settingsProvider Returns initialized instance or nil if initialization fails.
Initializes the processor to work with the given GBApplicationSettingsProvider implementor.
This is the designated initializer.
nil . GBCommentsProcessor.hGBCommentsProcessor.m Processes the given GBComment using the given context and store.
- (void)processComment:(GBComment *)comment withContext:(id < GBObjectDataProviding >)context store:(id)store GBObjectDataProviding identifying current context for handling links or nil . Processes the given GBComment using the given context and store.
This method processes the given comment's string value and prepares all derives values. It uses the given store for dependent values such as links and similar, so make sure the store has all possible objects already registered. In order to properly handle "local" links, the method also takes context parameter which identifies top-level object to which the object which's comment we're processing belongs to. You can pass nil however this prevents any local links being processed!
GBCommentsProcessor.hGBCommentsProcessor.m Processes the given GBComment using the given store.
- (void)processComment:(GBComment *)comment withStore:(id)store Processes the given GBComment using the given store.
This method processes the given comment's string value and prepares all derives values. It uses the given store for dependent values such as links and similar, so make sure the store has all possible objects already registered. Sending this message has the same effect as sending processComment:withContext:store: to receiver and passing nil for context.
Important: This method is provided for simpler unit testing and should not be used by the application. The most important reason for keeping it, is the fact that we introduced context handling when implementing links at which time we already had many unit tests relying on this method. So the easiest way for not being forced to refactor all these tests was to keep the method. It doesn't bloat the class interface either...
GBCommentsProcessor.hGBCommentsProcessor.m