public final class Interface extends NetDB<Interface>
| Modifier and Type | Class and Description |
|---|---|
static class |
Interface.COMPARISON_TYPE |
NetDB.FORMAT| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
JSON_COMMENT |
static java.lang.String |
JSON_DHCP |
static java.lang.String |
JSON_DHCP_OPTIONS |
static java.lang.String |
JSON_HW_ADDRESS |
static java.lang.String |
JSON_IPS |
static java.lang.String |
JSON_NAMES |
static java.lang.String |
JSON_ROAM |
static java.lang.String |
json_template_name
The template toJSON uses.
|
static java.lang.String |
JSON_TYPE |
static java.lang.String |
template_name
The template toString uses.
|
extra_data, UNPROCESSED_JSON| Constructor and Description |
|---|
Interface() |
Interface(Interface_Type type,
java.lang.Boolean roam,
java.lang.Boolean dhcp) |
Interface(Interface_Type type,
java.lang.Boolean roam,
java.lang.Boolean dhcp,
java.lang.String hardware_address,
java.lang.String comment) |
Interface(NetDB_Datastore datastore) |
Interface(NetDB_Datastore datastore,
Interface_Type type,
java.lang.Boolean roam,
java.lang.Boolean dhcp) |
Interface(NetDB_Datastore datastore,
Interface_Type type,
java.lang.Boolean roam,
java.lang.Boolean dhcp,
java.lang.String hardware_address,
java.lang.String comment) |
| Modifier and Type | Method and Description |
|---|---|
static java.lang.Boolean |
_has_access(java.lang.String transaction_name,
NetDB_Datastore datastore,
User user,
java.lang.String handle)
This method makes the DB call(s).
|
static void |
_move(java.lang.String transaction_name,
NetDB_Datastore datastore,
java.util.Map<java.lang.Long,java.lang.String> ifaces,
java.lang.String source_node,
java.lang.String destination_node)
This method makes the DB call(s).
|
Interface |
add_address(Interface_IP_Address address)
Add an address.
|
Interface |
add_addresses(java.util.Collection<Interface_IP_Address> addresses)
Add several addresses.
|
Interface |
add_dhcp_setting(DHCP_Setting setting)
Add a DHCP setting.
|
Interface |
add_DHCP_setting(DHCP_Setting setting)
Alias for add_dhcp_setting (...).
|
Interface |
add_dhcp_settings(java.util.Collection<DHCP_Setting> settings)
Add several DHCP settings.
|
Interface |
add_DHCP_settings(java.util.Collection<DHCP_Setting> settings)
Alias for add_dhcp_settings (...).
|
Interface |
add_name(A_Name name)
Add a name.
|
Interface |
add_names(java.util.Collection<A_Name> names)
Add several names.
|
java.util.Collection<Interface_IP_Address> |
addresses()
Fetch the IP addresses.
|
Interface |
bind(NetDB_Datastore datastore)
Binds this instance to datastore.
|
java.lang.Boolean |
can_roam()
Alias for roam ().
|
java.lang.String |
comment()
Fetch the comment.
|
Interface |
comment(java.lang.String comment)
Set the comment.
|
int |
compare(Interface interface_1,
Interface interface_2)
Interfaces have an unusual set of rules for sorting.
|
int |
compareTo(Interface that)
Compare two objects based on their handles (case blind).
|
java.util.Collection<DHCP_Setting> |
dhcp_settings()
Fetch the DHCP settings.
|
java.util.Collection<DHCP_Setting> |
DHCP_settings()
Alias for dhcp_settings ().
|
boolean |
dhcp()
Fetch the DHCP state.
|
boolean |
DHCP()
Alias for dhcp ().
|
Interface |
dhcp(java.lang.Boolean dhcp)
Set the DHCP usage state.
|
Interface |
DHCP(java.lang.Boolean use_dhcp)
Alias for dhcp (...).
|
Interface |
disable_dhcp()
Set the DHCP state to false.
|
Interface |
disable_DHCP()
Alias for disable_dhcp ().
|
Interface |
disable_roaming()
Set the roaming state to false.
|
Interface |
enable_dhcp()
Set the DHCP state to true.
|
Interface |
enable_DHCP()
Alias for enable_dhcp ().
|
Interface |
enable_roaming()
Set the roaming state to true.
|
java.lang.String |
handle()
The handle for an Interface can be one of three things: hardware_address, the first IP
address, or the ID.
|
java.lang.String |
hardware_address()
Fetch the hardware address.
|
Interface |
hardware_address(java.lang.String hardware_address)
Set the hardware address.
|
static java.lang.Boolean |
has_access(NetDB_Datastore datastore,
java.lang.String handle)
Make an access check using the operating user and specified datastore.
|
static java.lang.Boolean |
has_access(NetDB_Datastore datastore,
User user,
java.lang.String handle)
Check if the specified user has access to handle in the specified datastore.
|
static java.lang.Boolean |
has_access(java.lang.String handle)
Make an access check using the operating user and default datastore.
|
static java.lang.Boolean |
has_access(User user,
java.lang.String handle)
Make an access check using the specified user and default datastore.
|
java.lang.Long |
id()
Fetch the ID.
|
Interface |
id(java.lang.Long id)
Set the ID.
|
java.lang.Boolean |
is_dhcp_enabled()
Alias for dhcp ().
|
java.lang.Boolean |
is_DHCP_enabled()
Alias for dhcp ().
|
static void |
move(java.util.Map<java.lang.Long,java.lang.String> ifaces,
java.lang.String source_node,
java.lang.String destination_node)
Move interfaces using the default datastore.
|
static void |
move(NetDB_Datastore datastore,
java.util.Map<java.lang.Long,java.lang.String> ifaces,
java.lang.String source_node,
java.lang.String destination_node)
Move the interfaces passed from the source node to the destination node.
|
java.util.Collection<A_Name> |
names()
Fetch the names.
|
Interface |
new_instance()
Create a new instance of this class's type.
|
java.lang.Long |
node()
Fetch the parent node ID.
|
java.lang.String |
pretty_hardware_address()
Fetch the hardware address in a more human friendly form.
|
java.lang.String |
pretty_hardware_address(int characters_between_delimiter,
java.lang.String delimiter)
Return the hardware address in a slightly more human friendly form.
|
Interface |
remove_address(Interface_IP_Address address)
Remove an address.
|
Interface |
remove_addresses(java.util.Collection<Interface_IP_Address> addresses)
Remove several addresses.
|
Interface |
remove_dhcp_setting(DHCP_Setting setting)
Remove a DHCP setting.
|
Interface |
remove_DHCP_setting(DHCP_Setting setting)
Alias for remove_dhcp_setting (...).
|
Interface |
remove_dhcp_settings(java.util.Collection<DHCP_Setting> settings)
Remove several DHCP settings.
|
Interface |
remove_DHCP_settings(java.util.Collection<DHCP_Setting> settings)
Alias for remove_dhcp_settings (...).
|
Interface |
remove_name(A_Name name)
Remove a name.
|
Interface |
remove_names(java.util.Collection<A_Name> names)
Remove several names.
|
java.lang.Boolean |
roam()
Fetch the roaming state.
|
Interface |
roaming(java.lang.Boolean roam)
Set the roaming state.
|
java.lang.String |
single_value_attributes()
This method builds a String of all the single value attributes.
|
java.lang.Long |
sort_id()
Fetch the sort id.
|
Interface |
sort_id(java.lang.Integer sort_id)
Set the sort id.
|
Interface |
sort_id(java.lang.Long sort_id)
Set the sort id.
|
java.lang.String |
toJSON(java.lang.Boolean pretty,
java.lang.Boolean ignore_exceptions)
Convert this to a JSON object using the template defined in json_template_name.
|
java.lang.String |
toString(NetDB.FORMAT format,
java.lang.Boolean ignore_exceptions)
Convert this to a String using the template defined in template_name.
|
Interface_Type |
type()
Fetch the type.
|
Interface |
type(Interface_Type type)
Set the interface type.
|
Interface |
unbind()
Unlink this instance, and clear the datastore.
|
java.lang.String |
unique_identifier()
The HW address is the preferred external handle.
|
Interface |
unlink()
Treat this object as user created, and clear any datastore specific information.
|
autocomplete, autocomplete, clear_extra_data, compare, compare, complete, created_by_user, datastore, default_datastore, default_datastore, defined_or_die_handle, defined_or_die, equals, extra_data, extra_data, extra_data, fromJSON, is_bound, is_complete, is_partial, json_recovery_log, reset_timing, rmi_exception, timing, toJSON, toJSON, toJSON, toJSON, toString, toString, toString, toString, versionsort_comparatorbackup_logger, backup_logger, default_logger, default_logger, entered, entered, entered, exited, exited, exited, get_method_name, log_enter_exit, log_message, logger, loggerpublic static java.lang.String template_name
public static java.lang.String json_template_name
public static final java.lang.String JSON_DHCP
public static final java.lang.String JSON_ROAM
public static final java.lang.String JSON_COMMENT
public static final java.lang.String JSON_HW_ADDRESS
public static final java.lang.String JSON_NAMES
public static final java.lang.String JSON_IPS
public static final java.lang.String JSON_DHCP_OPTIONS
public static final java.lang.String JSON_TYPE
public Interface()
public Interface(Interface_Type type, java.lang.Boolean roam, java.lang.Boolean dhcp)
public Interface(Interface_Type type, java.lang.Boolean roam, java.lang.Boolean dhcp, java.lang.String hardware_address, java.lang.String comment) throws java.lang.Exception
java.lang.Exceptionpublic Interface(NetDB_Datastore datastore)
public Interface(NetDB_Datastore datastore, Interface_Type type, java.lang.Boolean roam, java.lang.Boolean dhcp)
public Interface(NetDB_Datastore datastore, Interface_Type type, java.lang.Boolean roam, java.lang.Boolean dhcp, java.lang.String hardware_address, java.lang.String comment) throws java.lang.Exception
java.lang.Exceptionpublic java.lang.Long id()
public java.lang.Long sort_id()
public Interface_Type type() throws java.lang.Exception, No_Datastore_Defined, Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_InformationNetDB.internal_complete(java.lang.Object, java.lang.Object, java.lang.String)public java.lang.Long node()
throws java.lang.Exception,
No_Datastore_Defined,
Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_InformationNetDB.internal_complete(java.lang.Object, java.lang.Object, java.lang.String)public java.lang.Boolean can_roam()
throws java.lang.Exception,
No_Datastore_Defined,
Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_Informationpublic java.lang.Boolean roam()
throws java.lang.Exception,
No_Datastore_Defined,
Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_InformationNetDB.internal_complete(java.lang.Object, java.lang.Object, java.lang.String)public java.lang.Boolean is_DHCP_enabled()
throws java.lang.Exception,
No_Datastore_Defined,
Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_Informationpublic java.lang.Boolean is_dhcp_enabled()
throws java.lang.Exception,
No_Datastore_Defined,
Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_Informationpublic boolean DHCP()
throws java.lang.Exception,
No_Datastore_Defined,
Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_Informationpublic boolean dhcp()
throws java.lang.Exception,
No_Datastore_Defined,
Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_InformationNetDB.internal_complete(java.lang.Object, java.lang.Object, java.lang.String)public java.lang.String hardware_address()
throws java.lang.Exception,
No_Datastore_Defined,
Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_InformationNetDB.internal_complete(java.lang.Object, java.lang.Object, java.lang.String)public java.lang.String pretty_hardware_address()
throws java.lang.Exception,
No_Datastore_Defined,
Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_Informationpretty_hardware_address(int,String)public java.lang.String pretty_hardware_address(int characters_between_delimiter,
java.lang.String delimiter)
throws java.lang.Exception,
No_Datastore_Defined,
Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_Informationhardware_addresspublic java.lang.String comment()
throws java.lang.Exception,
No_Datastore_Defined,
Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_InformationNetDB.internal_complete(java.lang.Object, java.lang.Object, java.lang.String)public java.util.Collection<DHCP_Setting> DHCP_settings() throws java.lang.Exception, No_Datastore_Defined, Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_Informationpublic java.util.Collection<DHCP_Setting> dhcp_settings() throws java.lang.Exception, No_Datastore_Defined, Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_InformationNetDB.internal_complete(java.lang.Object, java.lang.Object, java.lang.String)public java.util.Collection<A_Name> names() throws java.lang.Exception, No_Datastore_Defined, Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_InformationNetDB.internal_complete(java.lang.Object, java.lang.Object, java.lang.String)public java.util.Collection<Interface_IP_Address> addresses() throws java.lang.Exception, No_Datastore_Defined, Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_InformationNetDB.internal_complete(java.lang.Object, java.lang.Object, java.lang.String)public java.lang.String handle()
public java.lang.String unique_identifier()
unique_identifier in class NetDB<Interface>public Interface new_instance() throws java.lang.Exception
NetDBnew_instance in class NetDB<Interface>java.lang.Exceptionpublic Interface id(java.lang.Long id)
public Interface sort_id(java.lang.Long sort_id)
public Interface sort_id(java.lang.Integer sort_id)
public Interface type(Interface_Type type)
public Interface roaming(java.lang.Boolean roam)
public Interface DHCP(java.lang.Boolean use_dhcp)
public Interface dhcp(java.lang.Boolean dhcp)
public Interface hardware_address(java.lang.String hardware_address) throws java.lang.Exception
java.lang.Exceptionpublic Interface comment(java.lang.String comment)
public Interface add_DHCP_setting(DHCP_Setting setting)
public Interface add_dhcp_setting(DHCP_Setting setting)
public Interface add_DHCP_settings(java.util.Collection<DHCP_Setting> settings)
public Interface add_dhcp_settings(java.util.Collection<DHCP_Setting> settings)
public Interface remove_DHCP_setting(DHCP_Setting setting)
public Interface remove_dhcp_setting(DHCP_Setting setting)
public Interface remove_DHCP_settings(java.util.Collection<DHCP_Setting> settings)
public Interface remove_dhcp_settings(java.util.Collection<DHCP_Setting> settings)
public Interface remove_names(java.util.Collection<A_Name> names)
public Interface add_address(Interface_IP_Address address)
public Interface add_addresses(java.util.Collection<Interface_IP_Address> addresses)
public Interface remove_address(Interface_IP_Address address)
public Interface remove_addresses(java.util.Collection<Interface_IP_Address> addresses)
public Interface enable_DHCP()
public Interface enable_dhcp()
dhcp(Boolean)public Interface disable_DHCP()
public Interface disable_dhcp()
dhcp(Boolean)public Interface enable_roaming()
roaming(Boolean)public Interface disable_roaming()
roaming(Boolean)public Interface bind(NetDB_Datastore datastore) throws No_Datastore_Defined
NetDBbind in class NetDB<Interface>No_Datastore_Definedpublic Interface unbind()
NetDBpublic Interface unlink()
NetDBpublic java.lang.String single_value_attributes()
Attributesingle_value_attributes in class Attribute<Interface>Attribute.compare(Attribute),
Attribute.compare(Attribute,COMPARISON_TYPE)public java.lang.String toString(NetDB.FORMAT format, java.lang.Boolean ignore_exceptions) throws java.lang.Exception
public java.lang.String toJSON(java.lang.Boolean pretty,
java.lang.Boolean ignore_exceptions)
throws java.lang.Exception
public int compareTo(Interface that)
NetDBcompareTo in interface java.lang.Comparable<Interface>compareTo in class NetDB<Interface>compare(Interface,Interface)public int compare(Interface interface_1, Interface interface_2)
public static java.lang.Boolean has_access(java.lang.String handle)
throws java.lang.Exception,
No_Datastore_Defined,
Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_Informationhas_access(NetDB_Datastore,User,String)public static java.lang.Boolean has_access(User user, java.lang.String handle) throws java.lang.Exception, No_Datastore_Defined, Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_Informationhas_access(NetDB_Datastore,User,String)public static java.lang.Boolean has_access(NetDB_Datastore datastore, java.lang.String handle) throws java.lang.Exception, No_Datastore_Defined, Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_Informationhas_access(NetDB_Datastore,User,String)public static java.lang.Boolean has_access(NetDB_Datastore datastore, User user, java.lang.String handle) throws java.lang.Exception, No_Datastore_Defined, Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_Informationpublic static java.lang.Boolean _has_access(java.lang.String transaction_name,
NetDB_Datastore datastore,
User user,
java.lang.String handle)
throws java.lang.Exception
java.lang.Exceptionpublic static void move(java.util.Map<java.lang.Long,java.lang.String> ifaces,
java.lang.String source_node,
java.lang.String destination_node)
throws java.lang.Exception,
No_Datastore_Defined,
Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_Informationmove(Map,String,String)public static void move(NetDB_Datastore datastore, java.util.Map<java.lang.Long,java.lang.String> ifaces, java.lang.String source_node, java.lang.String destination_node) throws java.lang.Exception, No_Datastore_Defined, Insufficient_Information
java.lang.ExceptionNo_Datastore_DefinedInsufficient_Informationpublic static void _move(java.lang.String transaction_name,
NetDB_Datastore datastore,
java.util.Map<java.lang.Long,java.lang.String> ifaces,
java.lang.String source_node,
java.lang.String destination_node)
throws java.lang.Exception
java.lang.Exception