org.openoffice.da.comp.w2lcommon.helper
Class StyleNameProvider

java.lang.Object
  extended by org.openoffice.da.comp.w2lcommon.helper.StyleNameProvider

public class StyleNameProvider
extends java.lang.Object

This class provides access to the style names and localized style names of the current document


Constructor Summary
StyleNameProvider(com.sun.star.uno.XComponentContext xContext)
          Construct a new StyleNameProvider
 
Method Summary
 java.util.Map<java.lang.String,java.lang.String> getDisplayNames(java.lang.String sFamily)
          Get the mapping of internal names to display names for a style family
 java.util.Map<java.lang.String,java.lang.String> getInternalNames(java.lang.String sFamily)
          Get the mapping of display names to internal names for a style family
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StyleNameProvider

public StyleNameProvider(com.sun.star.uno.XComponentContext xContext)
Construct a new StyleNameProvider

Parameters:
xContext - the componemt context to get the desktop from
Method Detail

getDisplayNames

public java.util.Map<java.lang.String,java.lang.String> getDisplayNames(java.lang.String sFamily)
Get the mapping of internal names to display names for a style family

Parameters:
sFamily - the style family (for text documents this should be CharacterStyles, ParagraphStyles, FrameStyles, PageStyles or NumberingStyles)
Returns:
a read only map from internal names to display names, or null if the family is not known to the provider

getInternalNames

public java.util.Map<java.lang.String,java.lang.String> getInternalNames(java.lang.String sFamily)
Get the mapping of display names to internal names for a style family

Parameters:
sFamily - the style family (for text documents this should be CharacterStyles, ParagraphStyles, FrameStyles, PageStyles or NumberingStyles)
Returns:
a read only map from display names to internal names, or null if the family is not known to the provider