Skip to Content
Python: Master the Art of Design Patterns
book

Python: Master the Art of Design Patterns

by Dusty Phillips, Chetan Giridhar, Sakis Kasampalis
September 2016
Intermediate to advanced
775 pages
18h 22m
English
Packt Publishing
Content preview from Python: Master the Art of Design Patterns

Serializing objects

Nowadays, we take the ability to write data to a file and retrieve it at an arbitrary later date for granted. As convenient as this is (imagine the state of computing if we couldn't store anything!), we often find ourselves converting data we have stored in a nice object or design pattern in memory into some kind of clunky text or binary format for storage, transfer over the network, or remote invocation on a distant server.

The Python pickle module is an object-oriented way to store objects directly in a special storage format. It essentially converts an object (and all the objects it holds as attributes) into a sequence of bytes that can be stored or transported however we see fit.

For basic work, the pickle module has an extremely ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Python for Programmers

Python for Programmers

Paul Deitel, Harvey Deitel
Head First Design Patterns, 2nd Edition

Head First Design Patterns, 2nd Edition

Eric Freeman, Elisabeth Robson
Fluent Python

Fluent Python

Luciano Ramalho

Publisher Resources

ISBN: 9781787125186Purchase Link