public interface IContentFormatter
The content formatter is assumed to determine the partitioning of the document range to be formatted. For each partition, the formatter determines based on the partition's content type the formatting strategy to be used. Before the first strategy is activated all strategies are informed about the start of the formatting process. After that, the formatting strategies are activated in the sequence defined by the partitioning of the document range to be formatted. It is assumed that a strategy must be finished before the next strategy can be activated. After the last strategy has been finished, all strategies are informed about the termination of the formatting process.
The interface can be implemented by clients. By default, clients use
MultiPassContentFormatter as the standard implementers of this interface.
|Modifier and Type||Method and Description|
Formats the given region of the specified document.The formatter may safely assume that it is the only subject that modifies the document at this point in time.
Returns the formatting strategy registered for the given content type.
document- the document to be formatted
region- the region within the document to be formatted
IFormattingStrategy getFormattingStrategy(String contentType)
contentType- the content type for which to look up the formatting strategy
nullif there is no such strategy
Copyright (c) 2000, 2016 Eclipse Contributors and others. All rights reserved.Guidelines for using Eclipse APIs.