MAP Databasing System
MAP Databasing System © 2025 by Pixelated Dream is licensed under CC BY-ND 4.0
MAP Databasing System is an incredibly intuitive and simple system for databases that are flexible, fast, and robust. To get started, create a mapdb object either with a context manager or with the pull() and push() functions, then you can begin interacting with the object.
Context Manager
import mapdbsys as mdb # Import the library under the name 'mdb'
with mdb.mapdb("map_file.map") as mapfile: # Context Manager
for key, values in mapfile.items(): # Iterate through the mapfile entries' keys and values
print(f'Key \'{key}\' has {len(values)} values; {', '.join(values)') # Print data about entry
mapfile['myEntry'] = ['myValue'] # Set 'myEntry' to 'MyValue
Pull/Push Function
import mapdbsys as mdb # Import the library under the name 'mdb'
mapfile = mdb.pull('map_file.map') # Open a map file and save the object representation to a variable
# Reference the contents through *.entries instead of just *
for key, values in mapfile.entries.items(): # Iterate through the mapfile entries' keys and values
print(f'Key \'{key}\' has {len(values)} values. ({', '.join(values)}') # Print data about entry
mapfile.entries['myEntry'] = ['myValue'] # Set 'myEntry' to 'MyValue
mapfile.push() # Push changes back into database
Versions
-
0.1.1 OPEN BETA
- Python Library (Script)
- Documentation Markdown File (CURRENTLY EMPTY)
- License Changelog (File Download)
Added more detailed comments and comments to spots without them
Commented on context manager class
Added functions for interacting with map databases without a context manager (YOU SHOULD STILL USE CONTEXT MANAGERS!)
pull() function takes a file path and returns a mapdb object
push() function called on a mapdb object to push changes back into a database and closes the mapdb object
Revamped dict_to_map() and map_to_dict() functions and also fixed parsing issues
Incorrect parsing of individual entries
Entries would get parsed into a whole entry due to overall counterintuitive functions
Splitting of values into individual characters
Values would be split into single characters - EDIT: This effect was a result of my utter ignorance when setting entries where if you do not set a key to a list it will do this; BE CAREFUL!
Overall cleaner and easier to comprehend