AO Net Types

project: current stablemanagement: productionpackaging: active
java: >= 6semantic versioning: 2.0.0license: LGPL v3

Networking-related value types for Java.

Features

  • IPv4 and IPv6 address families.
  • Individual addresses and network ranges.
  • Protocols, ports, and port ranges.
  • Supports optimization through reduction of IP and port combinations through:
    • Coalescing of addresses and network ranges into fewer network ranges.
    • Coalescing of ports and port ranges into fewer port ranges.
  • Fast serializable and self-validating objects.
  • Internable for memory savings on large datasets.
  • Small footprint, minimal dependencies - not part of a big monolithic package.
  • Java 1.6 implementation:
    • Android compatible.
    • Java EE 6+ compatible.

Motivation

The AOServ Platform allows configuration of services on a per-port and per-IP basis. System configuration components like AO SELinux and AO firewalld support configurations over port ranges and network ranges.

These value types are a common representation of networking configuration shared between various components. They have minimal dependencies and may be useful for projects needing to go beyond the stock java.net.* classes.

Evaluated Alternatives

Admittedly, several features of this API are redundant with the standard Java API. This API has a long history and, as the Java platform matures, is increasingly redundant. When it is sufficient for your needs, please prefer the standard Java API.