Skip to content

Commit dd30628

Browse files
committed
Enhancing the LoadProfileSource to return the resolution
1 parent ad22242 commit dd30628

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
99
### Added
1010
- Enhanced check for invalid field names in sources [#1383](https://github.com/ie3-institute/PowerSystemDataModel/issues/1383)
1111
- Enhancing value retrieval in `TimeSeriesSource` [1280](https://github.com/ie3-institute/PowerSystemDataModel/issues/1280)
12+
- Enhancing the `LoadProfileSource` to return the resolution [1288](https://github.com/ie3-institute/PowerSystemDataModel/issues/1288)
1213

1314
### Fixed
1415

src/main/java/edu/ie3/datamodel/io/source/LoadProfileSource.java

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,17 @@ protected Try<LoadProfileEntry<V>, FactoryException> createEntries(
8888
/** Returns the load profile energy scaling for this load profile time series. */
8989
public abstract Optional<ComparableQuantity<Energy>> getLoadProfileEnergyScaling();
9090

91+
/**
92+
* Returns the resolution for the given {@link LoadProfile}.
93+
*
94+
* @param loadProfile given load profile
95+
* @return the resolution in seconds.
96+
*/
97+
public static long getResolution(LoadProfile loadProfile) {
98+
// currently all registered profiles and all sources use 15 minutes intervals
99+
return 900L;
100+
}
101+
91102
/**
92103
* Method to read in the build-in {@link BdewStandardLoadProfile}s.
93104
*

0 commit comments

Comments
 (0)