How To Install xstream on Fedora 34

xstream is Java XML serialization library

Introduction

In this tutorial we learn how to install xstream on Fedora 34.

What is xstream

XStream is a simple library to serialize objects to XML and back again. A high level facade is supplied that simplifies common use cases. Custom objects can be serialized without need for specifying mappings. Speed and low memory footprint are a crucial part of the design, making it suitable for large object graphs or systems with high message throughput. No information is duplicated that can be obtained via reflection. This results in XML that is easier to read for humans and more compact than native Java serialization. XStream serializes internal fields, including private and final. Supports non-public and inner classes. Classes are not required to have default constructor. Duplicate references encountered in the object-model will be maintained. Supports circular references. By implementing an interface, XStream can serialize directly to/from any tree structure (not just XML). Strategies can be registered allowing customization of how particular types are represented as XML. When an exception occurs due to malformed XML, detailed diagnostics are provided to help isolate and fix the problem.

We can use yum or dnf to install xstream on Fedora 34. In this tutorial we discuss both methods but you only need to choose one of method to install xstream.

Install xstream on Fedora 34 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

The output should look something like this:

Fedora 34 - x86_64                               20 kB/s | 6.6 kB     00:00
Fedora 34 openh264 (From Cisco) - x86_64        1.4 kB/s | 989  B     00:00
Fedora Modular 34 - x86_64                       68 kB/s | 6.5 kB     00:00
Fedora 34 - x86_64 - Updates                    3.5 kB/s | 6.2 kB     00:01
Fedora Modular 34 - x86_64 - Updates             17 kB/s | 5.9 kB     00:00
Metadata cache created.

After updating yum database, We can install xstream using dnf by running the following command:

sudo dnf -y install xstream

Install xstream on Fedora 34 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

The output should look something like this:

Fedora 34 - x86_64                               20 kB/s | 6.6 kB     00:00
Fedora 34 openh264 (From Cisco) - x86_64        1.4 kB/s | 989  B     00:00
Fedora Modular 34 - x86_64                       68 kB/s | 6.5 kB     00:00
Fedora 34 - x86_64 - Updates                    3.5 kB/s | 6.2 kB     00:01
Fedora Modular 34 - x86_64 - Updates             17 kB/s | 5.9 kB     00:00
Metadata cache created.

After updating yum database, We can install xstream using yum by running the following command:

sudo yum -y install xstream

How To Uninstall xstream on Fedora 34

To uninstall only the xstream package we can use the following command:

sudo dnf remove xstream

xstream Package Contents on Fedora 34

/usr/share/doc/xstream
/usr/share/doc/xstream/README.txt
/usr/share/java/xstream
/usr/share/java/xstream.jar
/usr/share/java/xstream/xstream.jar
/usr/share/licenses/xstream
/usr/share/licenses/xstream/LICENSE.txt
/usr/share/maven-metadata/xstream.xml
/usr/share/maven-poms/xstream
/usr/share/maven-poms/xstream.pom
/usr/share/maven-poms/xstream/xstream.pom

References

Summary

In this tutorial we learn how to install xstream on Fedora 34 using yum and dnf.