Package com.powsybl.sensitivity
Class JsonSensitivityFactorsProvider
- java.lang.Object
-
- com.powsybl.sensitivity.JsonSensitivityFactorsProvider
-
- All Implemented Interfaces:
SensitivityFactorsProvider
public class JsonSensitivityFactorsProvider extends Object implements SensitivityFactorsProvider
-
-
Constructor Summary
Constructors Constructor Description JsonSensitivityFactorsProvider(InputStream input)
Creates a provider by reading the sensitivity factors from a JSON UTF-8 encoded input stream.JsonSensitivityFactorsProvider(Path path)
Creates a provider by reading the sensitivity factors from a JSON UTF-8 encoded file.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<SensitivityFactor>
getFactors(Network network)
Get the list of factors generated based on the given networkList<SensitivityFactor>
getFactors(Network network, String contingencyId)
Get the list of factors generated based on the given network and a contingency
-
-
-
Constructor Detail
-
JsonSensitivityFactorsProvider
public JsonSensitivityFactorsProvider(Path path)
Creates a provider by reading the sensitivity factors from a JSON UTF-8 encoded file.
-
JsonSensitivityFactorsProvider
public JsonSensitivityFactorsProvider(InputStream input)
Creates a provider by reading the sensitivity factors from a JSON UTF-8 encoded input stream.
-
-
Method Detail
-
getFactors
public List<SensitivityFactor> getFactors(Network network)
Description copied from interface:SensitivityFactorsProvider
Get the list of factors generated based on the given network- Specified by:
getFactors
in interfaceSensitivityFactorsProvider
- Parameters:
network
- Base IIDM network of provision method- Returns:
- A list of sensitivity factors
-
getFactors
public List<SensitivityFactor> getFactors(Network network, String contingencyId)
Description copied from interface:SensitivityFactorsProvider
Get the list of factors generated based on the given network and a contingency- Specified by:
getFactors
in interfaceSensitivityFactorsProvider
- Parameters:
network
- Base IIDM network of provision methodcontingencyId
- Id of the contingency for which we want the factors. Set to null for base case factors.- Returns:
- A list of sensitivity factors
-
-