Klasse VirtualizedNetwork

java.lang.Object
de.bytestore.hostinger.extension.virtualization.network.VirtualizedNetwork

public class VirtualizedNetwork extends Object
The VirtualizedNetwork class represents a virtualized network configuration. The class provides various properties for storing information about the network configuration, such as the network type, interface, IP addresses, gateways, netmasks, and IP assignment methods. The IPType enum is used to specify whether the IP addresses are assigned via DHCP or statically. This class provides getter and setter methods for each property. Usage: // Create a new VirtualizedNetwork object VirtualizedNetwork network = new VirtualizedNetwork(); // Set the network type network.setType("Ethernet"); // Set the network interface network.setIface("eth0"); // Set the IPv4 address network.setIpV4("192.168.0.10"); // Set the IPv6 address network.setIpV6("2001:0db8:85a3:0000:0000:8a2e:0370:7334"); // Set the IPv4 gateway network.setGatewayV4("192.168.0.1"); // Set the IPv6 gateway network.setGatewayV6("2001:0db8:85a3:0000:0000:8a2e:0370:7331"); // Set the IPv4 netmask network.setNetmaskV4(24); // Set the IPv6 netmask network.setNetmaskV6(64); // Set the IP assignment method for IPv4 network.setMethodV4(IPType.STATIC); // Set the IP assignment method for IPv6 network.setMethodV6(IPType.DHCP); // Get the network type String type = network.getType(); // Get the network interface String iface = network.getIface(); // Get the IPv4 address String ipV4 = network.getIpV4(); // Get the IPv6 address String ipV6 = network.getIpV6(); // Get the IPv4 gateway String gatewayV4 = network.getGatewayV4(); // Get the IPv6 gateway String gatewayV6 = network.getGatewayV6(); // Get the IPv4 netmask int netmaskV4 = network.getNetmaskV4(); // Get the IPv6 netmask int netmaskV6 = network.getNetmaskV6(); // Get the IP assignment method for IPv4 IPType methodV4 = network.getMethodV4(); // Get the IP assignment method for IPv6 IPType methodV6 = network.getMethodV6();
  • Konstruktordetails

    • VirtualizedNetwork

      public VirtualizedNetwork()