com.rubecula.util
Interface StylishWriteable


public interface StylishWriteable

Class to represent an object which can be written to using a specific style.

Since:
V_0_3
Version:
$Revision: 1.4 $
Author:
Robin Hillyard

Method Summary
 boolean addStyle(Style style)
          Method to add a style into this StylishWriteable object's current style.
 boolean appendString(java.lang.String string)
          Method to insert a styled-string into a StylishWriteable object at end.
 boolean insertString(int offset, java.lang.String string)
          Method to insert a styled-string into a StylishWriteable object at offset int.
 void popStyle()
          Method to pop the appropriate style from this StylishWriteable object's style stack.
 void pushStyle()
          Method to push the current style onto this StylishWriteable object's style stack so that it can be retrieved later.
 

Method Detail

pushStyle

public void pushStyle()
Method to push the current style onto this StylishWriteable object's style stack so that it can be retrieved later. This method should be called when a nested Documentable is encountered, before recursively presenting the new branch.


addStyle

public boolean addStyle(Style style)
Method to add a style into this StylishWriteable object's current style.

Parameters:
style - the style.
Returns:
true if successful.

popStyle

public void popStyle()
Method to pop the appropriate style from this StylishWriteable object's style stack. This method should be called when a nested Documentable is encountered, after recursively presenting the new branch.


insertString

public boolean insertString(int offset,
                            java.lang.String string)
Method to insert a styled-string into a StylishWriteable object at offset int.

Parameters:
offset - the offset.
string - the string.
Returns:
true if successful.

appendString

public boolean appendString(java.lang.String string)
Method to insert a styled-string into a StylishWriteable object at end.

Parameters:
string - the string.
Returns:
true if successful.