Python Forum
Organizing several similar classes with overlapping variables
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Organizing several similar classes with overlapping variables
#5
(May-06-2023, 10:18 PM)6hearts Wrote: I really do not have much functionality on them, except for storing data. And I mostly just need to lookup data,
Dataclases are probably the appropriate tools instead of dictionaries, and it solves the problem of identifying the type of the objects in a collection with mixed objects. Namedtuples could perhaps be used too.
Reply


Messages In This Thread
RE: Organizing several similar classes with overlapping variables - by Gribouillis - May-07-2023, 06:14 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Unexpected Output - Python Dataframes: Filtering based on Overlapping Dates Xensor 5 936 Nov-15-2023, 06:54 PM
Last Post: deanhystad
  Find overlapping date in database Hilal 2 1,804 Dec-18-2021, 08:15 PM
Last Post: Hilal
  Sum similar items tester_V 3 2,138 Jun-29-2021, 06:58 AM
Last Post: tester_V
  Organizing list of objects by attribute scarney1988 3 2,371 Mar-11-2020, 03:55 PM
Last Post: scarney1988
  Organizing Data in Dictionary Ranjirock 3 2,782 Aug-27-2019, 02:48 PM
Last Post: Ranjirock
  I can't use file __init__ to store shared variables and classes in the package AlekseyPython 2 3,485 Feb-04-2019, 06:26 AM
Last Post: AlekseyPython
  Python: if 'X' in 'Y' but with two similar strings as 'X' DreamingInsanity 6 4,045 Feb-01-2019, 01:28 PM
Last Post: buran
  How can classes access each other Functions and Variables at the same time PythonOK 4 3,208 Dec-09-2018, 03:46 AM
Last Post: ichabod801
  Similar to Poker bluekade5050 1 42,038 Nov-14-2018, 04:46 PM
Last Post: j.crater
  organizing by distance gonzo620 7 4,178 Oct-16-2018, 01:41 AM
Last Post: stullis

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020