Package com.powsybl.sld.util
Class AbstractBaseVoltageDiagramStyleProvider
- java.lang.Object
-
- com.powsybl.sld.svg.DefaultDiagramStyleProvider
-
- com.powsybl.sld.util.AbstractBaseVoltageDiagramStyleProvider
-
- All Implemented Interfaces:
DiagramStyleProvider
- Direct Known Subclasses:
NominalVoltageDiagramStyleProvider
,TopologicalStyleProvider
public abstract class AbstractBaseVoltageDiagramStyleProvider extends DefaultDiagramStyleProvider
- Author:
- Geoffroy Jamgotchian
, Franck Lecuyer , Florian Dupuy
-
-
Field Summary
Fields Modifier and Type Field Description protected static String
BASE_VOLTAGE_PROFILE
protected com.powsybl.commons.config.BaseVoltagesConfig
baseVoltagesConfig
protected com.powsybl.iidm.network.Network
network
-
Constructor Summary
Constructors Modifier Constructor Description protected
AbstractBaseVoltageDiagramStyleProvider(com.powsybl.commons.config.BaseVoltagesConfig baseVoltagesConfig, com.powsybl.iidm.network.Network network)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected Map<FeederWithSideNode.Side,Boolean>
connectionStatus(FeederWithSideNode node)
List<String>
getBusStyles(String busId, VoltageLevelGraph graph)
List<String>
getCssFilenames()
protected Optional<String>
getEdgeStyle(Edge edge)
Return the style if any applied to given edgeprotected Optional<String>
getHighlightLineStateStyle(Edge edge)
Return the highlight style if any to apply to given edge (ifLayoutParameters.isHighlightLineState()
)List<String>
getSvgNodeStyles(Node node, ComponentLibrary componentLibrary, boolean showInternalNodes)
List<String>
getSvgNodeSubcomponentStyles(Node node, String subComponentName)
Optional<String>
getVoltageLevelNodeStyle(VoltageLevelInfos vlInfo, Node node)
Returns the voltage level style if any to apply to the given node-
Methods inherited from class com.powsybl.sld.svg.DefaultDiagramStyleProvider
getCssUrls, getSvgNodeDecoratorStyles, getSvgWireStyles, getZoneLineStyles, isConstantColor, isConstantColor, reset
-
-
-
-
Field Detail
-
BASE_VOLTAGE_PROFILE
protected static final String BASE_VOLTAGE_PROFILE
- See Also:
- Constant Field Values
-
network
protected final com.powsybl.iidm.network.Network network
-
baseVoltagesConfig
protected final com.powsybl.commons.config.BaseVoltagesConfig baseVoltagesConfig
-
-
Method Detail
-
getEdgeStyle
protected Optional<String> getEdgeStyle(Edge edge)
Description copied from class:DefaultDiagramStyleProvider
Return the style if any applied to given edge- Overrides:
getEdgeStyle
in classDefaultDiagramStyleProvider
- Parameters:
edge
- the edge on which the style if any is applied to- Returns:
- the style if any
-
getSvgNodeStyles
public List<String> getSvgNodeStyles(Node node, ComponentLibrary componentLibrary, boolean showInternalNodes)
- Specified by:
getSvgNodeStyles
in interfaceDiagramStyleProvider
- Overrides:
getSvgNodeStyles
in classDefaultDiagramStyleProvider
-
getHighlightLineStateStyle
protected Optional<String> getHighlightLineStateStyle(Edge edge)
Description copied from class:DefaultDiagramStyleProvider
Return the highlight style if any to apply to given edge (ifLayoutParameters.isHighlightLineState()
)- Overrides:
getHighlightLineStateStyle
in classDefaultDiagramStyleProvider
- Parameters:
edge
- the edge on which the style if any is applied to- Returns:
- the highlight style if any
-
connectionStatus
protected Map<FeederWithSideNode.Side,Boolean> connectionStatus(FeederWithSideNode node)
-
getSvgNodeSubcomponentStyles
public List<String> getSvgNodeSubcomponentStyles(Node node, String subComponentName)
- Specified by:
getSvgNodeSubcomponentStyles
in interfaceDiagramStyleProvider
- Overrides:
getSvgNodeSubcomponentStyles
in classDefaultDiagramStyleProvider
-
getVoltageLevelNodeStyle
public Optional<String> getVoltageLevelNodeStyle(VoltageLevelInfos vlInfo, Node node)
Returns the voltage level style if any to apply to the given node- Parameters:
vlInfo
- the VoltageLevelInfos related to the given nodenode
- the node on which the style if any is applied to- Returns:
- the voltage level style if any
-
getBusStyles
public List<String> getBusStyles(String busId, VoltageLevelGraph graph)
- Specified by:
getBusStyles
in interfaceDiagramStyleProvider
- Overrides:
getBusStyles
in classDefaultDiagramStyleProvider
-
getCssFilenames
public List<String> getCssFilenames()
- Specified by:
getCssFilenames
in interfaceDiagramStyleProvider
- Overrides:
getCssFilenames
in classDefaultDiagramStyleProvider
-
-