Skip to content

Commit

Permalink
rename MAX_CHILDREN to MAX_CHILDREN_PER_GROUP
Browse files Browse the repository at this point in the history
  • Loading branch information
t20100 committed May 3, 2024
1 parent a5d9781 commit 0d262bd
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/silx/io/tiledh5.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ def _get_children(
container: tiled.client.container.Container,
max_children: int | None = None,
):
"""Return first max_children entries of given container as commonh5 wrappers.
"""Return first max_children entries of given container as a dict of commonh5 wrappers.
:param parent: The commonh5 wrapper for which to retrieve children.
:param container: The tiled container from which to retrieve the entries.
Expand Down Expand Up @@ -77,7 +77,7 @@ def _get_children(
class TiledH5(commonh5.File):
"""tiled client wrapper"""

MAX_CHILDREN: int | None = None
MAX_CHILDREN_PER_GROUP: int | None = None
"""Maximum number of children to instantiate for each group.
Set to None for allowing an unbound number of children per group.
Expand All @@ -102,7 +102,7 @@ def close(self):

@lru_cache
def _get_items(self):
return _get_children(self, self.__container, self.MAX_CHILDREN)
return _get_children(self, self.__container, self.MAX_CHILDREN_PER_GROUP)


class TiledGroup(commonh5.Group):
Expand All @@ -120,7 +120,7 @@ def __init__(

@lru_cache
def _get_items(self):
return _get_children(self, self.__container, self.file.MAX_CHILDREN)
return _get_children(self, self.__container, self.file.MAX_CHILDREN_PER_GROUP)


class TiledDataset(commonh5.LazyLoadableDataset):
Expand Down

0 comments on commit 0d262bd

Please sign in to comment.