Skip to content

Commit

Permalink
Add validation, fine-tune docstrings and exports
Browse files Browse the repository at this point in the history
  • Loading branch information
GabrielKS committed Sep 25, 2024
1 parent 9af1bbd commit fa6080f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions src/PowerSystems.jl
Original file line number Diff line number Diff line change
Expand Up @@ -480,10 +480,10 @@ export generate_struct_files
export ComponentSelector
export SingularComponentSelector
export PluralComponentSelector
export DynamicallyGroupedComponentSelector
export subtype_to_string
export component_to_qualified_string
export make_selector
export get_components
export get_groups
#################################################################################
# Imports
Expand Down Expand Up @@ -605,7 +605,7 @@ import InfrastructureSystems:
ComponentSelector,
SingularComponentSelector,
PluralComponentSelector,
DynamicallyGroupedPluralComponentSelector,
DynamicallyGroupedComponentSelector,
NameComponentSelector,
ListComponentSelector,
SubtypeComponentSelector,
Expand Down
6 changes: 3 additions & 3 deletions src/component_selector.jl
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ get_groups(e::ComponentSelector, sys::System; filterby = nothing) =
`PluralComponentSelector` represented by an `AggregationTopology` and a subtype of
`Component`.
"""
struct TopologyComponentSelector <: DynamicallyGroupedPluralComponentSelector
struct TopologyComponentSelector <: DynamicallyGroupedComponentSelector
component_subtype::Type{<:Component}
topology_subtype::Type{<:AggregationTopology}
topology_name::AbstractString
Expand All @@ -37,7 +37,7 @@ end
# Construction
"""
Make a `ComponentSelector` from an `AggregationTopology` and a type of component. Optionally
provide a name for the `ComponentSelector`.
provide a name and/or grouping behavior for the `ComponentSelector`.
"""
make_selector(
component_subtype::Type{<:Component},
Expand All @@ -50,7 +50,7 @@ make_selector(
topology_subtype,
topology_name,
name,
groupby,
IS.validate_groupby(groupby),
)

# Naming
Expand Down

0 comments on commit fa6080f

Please sign in to comment.