mirror of
https://github.com/sigmasternchen/xtext-core
synced 2025-03-16 08:48:55 +00:00
[xtext][formatter] Added missing author information
Change-Id: I17d7b51e69ae7916a1dc8658c1f970b8ea0bf4a5
This commit is contained in:
parent
24197724d5
commit
196296613d
3 changed files with 15 additions and 2 deletions
|
@ -6,7 +6,7 @@
|
|||
* semantic model.</p>
|
||||
*
|
||||
* <p>This infrastructure is capable of formatting documents based on the node model and based on the serializer's output.
|
||||
* The actual formatting is done by constructing a list of text replacements. Applying the text replacement turns the
|
||||
* The actual formatting is done by constructing a list of text replacements. Applying the text replacements turns the
|
||||
* unformatted document into a formatted document. Purpose of this infrastructure is to make it convenient for
|
||||
* implementers to construct these text replacements.</p>
|
||||
*
|
||||
|
|
|
@ -31,17 +31,27 @@ class GenericFormatterTester {
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @author Moritz Eysholdt - Initial contribution and API
|
||||
*/
|
||||
class FormatterTesterWithImpl extends FormatterTester {
|
||||
override protected createFormatter(FormatterTestRequest req) {
|
||||
(req as GenericFormatterTestRequest).formatter
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @author Moritz Eysholdt - Initial contribution and API
|
||||
*/
|
||||
class GenericFormatterTestRequest extends FormatterTestRequest {
|
||||
@Accessors GenericFormatter<? extends EObject> formatter
|
||||
}
|
||||
|
||||
@Accessors abstract class GenericFormatter<T extends EObject> extends AbstractFormatter2 {
|
||||
/**
|
||||
* @author Moritz Eysholdt - Initial contribution and API
|
||||
*/
|
||||
@Accessors
|
||||
abstract class GenericFormatter<T extends EObject> extends AbstractFormatter2 {
|
||||
def dispatch format(EObject obj, IFormattableDocument document) {
|
||||
format(obj as T, request.textRegionAccess, document)
|
||||
}
|
||||
|
|
|
@ -116,6 +116,9 @@ class RegionSetTest {
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @author Moritz Eysholdt - Initial contribution and API
|
||||
*/
|
||||
@FinalFieldsConstructor class TestableTextSegmentSet {
|
||||
val List<String> issues = newArrayList
|
||||
val TextSegmentSet<ITextSegment> set
|
||||
|
|
Loading…
Reference in a new issue