Skip to content

Commit

Permalink
Add a getAvailableCollections
Browse files Browse the repository at this point in the history
  • Loading branch information
jmcarcell committed Jan 8, 2024
1 parent 308b33f commit e1847ff
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion python/podio/frame.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,14 +110,22 @@ def __init__(self, data=None):

self._param_key_types = self._get_param_keys_types()

def getAvailableCollections(self):
"""Get the currently available collection (names) from this Frame.
Returns:
tuple(str): The names of the available collections from this Frame.
"""
return tuple(self._frame.getAvailableCollections())

@property
def collections(self):
"""Get the currently available collection (names) from this Frame.
Returns:
tuple(str): The names of the available collections from this Frame.
"""
return tuple(str(s) for s in self._frame.getAvailableCollections())
return self.getAvailableCollections()

def get(self, name):
"""Get a collection from the Frame by name.
Expand Down

0 comments on commit e1847ff

Please sign in to comment.