Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Java Programming for Beginners

You're reading from   Java Programming for Beginners Learn the fundamentals of programming with Java

Arrow left icon
Product type Paperback
Published in Oct 2017
Publisher Packt
ISBN-13 9781788296298
Length 318 pages
Edition 1st Edition
Languages
Arrow right icon
Author (1):
Arrow left icon
SkillSprints Inc., Mark Lassoff SkillSprints Inc., Mark Lassoff
Author Profile Icon SkillSprints Inc., Mark Lassoff
SkillSprints Inc., Mark Lassoff
Arrow right icon
View More author details
Toc

The Serializable class

Often, when we're dealing with information outside of our actual code, we're dealing with human-readable text that we've gotten from a file or are writing to a file or from an input or output stream. However, sometimes, human-readable text is just not convenient, and we'd like to use information that's more computer friendly. Through a process called serialization, we can take some Java objects and convert them into a binary stream that we could transfer across programs. This is not a human-friendly approach, as we'll see in this section. A serialized object looks like complete gibberish to us, but another Java program that knows about that object's class can recreate an object from that serialized information.

Not all Java objects can be serialized, though. In order for us to serialize an object, it needs to be marked...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime