public class

NetProperties

extends Object
java.lang.Object
   ↳ sun.net.NetProperties

Summary

Public Methods
static String get(String key)
Get a networking system property.
static Boolean getBoolean(String key)
Get a Boolean networking system property.
static Integer getInteger(String key, int defval)
Get an Integer networking system property.
[Expand]
Inherited Methods
From class java.lang.Object

Public Methods

public static String get (String key)

Get a networking system property. If no system property was defined returns the default value, if it exists, otherwise returns null.

Parameters
key the property name.
Returns
  • the String value for the property, or null
Throws
SecurityException if a security manager exists and its checkPropertiesAccess method doesn't allow access to the system properties.

public static Boolean getBoolean (String key)

Get a Boolean networking system property. If no system property was defined returns the default value, if it exists, otherwise returns null.

Parameters
key the property name.
Returns
  • the Boolean value for the property, or null
Throws
SecurityException if a security manager exists and its checkPropertiesAccess method doesn't allow access to the system properties.

public static Integer getInteger (String key, int defval)

Get an Integer networking system property. If no system property was defined returns the default value, if it exists, otherwise returns null.

Parameters
key the property name.
defval the default value to use if the property is not found
Returns
  • the Integer value for the property, or null
Throws
SecurityException if a security manager exists and its checkPropertiesAccess method doesn't allow access to the system properties.