org.nhindirect.config.manager
Class DNSRecordCommands

java.lang.Object
  extended by org.nhindirect.config.manager.DNSRecordCommands

public class DNSRecordCommands
extends Object

Command definition and logic for managing DNS records. Commands are case-insensitive.

Since:
1.0
Author:
Greg Meyer

Constructor Summary
DNSRecordCommands(org.nhind.config.ConfigurationServiceProxy proxy)
          Constructor that takes a reference to the configuration service proxy.
 
Method Summary
 void addANAME(String[] args)
          Adds an A records to the configuration service.
 void addMX(String[] args)
          Adds an MX records to the configuration service.
 void addSOA(String[] args)
          Adds an SOA records to the configuration service.
 void ensureANAME(String[] args)
          Adds an A records to the configuration service only if the record does not exist.
 void ensureMX(String[] args)
          Adds an MX records to the configuration service only if the record does not exist.
 void ensureSOA(String[] args)
          Adds an SOA records to the configuration service only if the record does not exist.
 void getAll(String[] args)
          Retrieves and prints all records in the configuration store.
 void getANAME(String[] args)
          Looks up an A record by record id.
 void getMX(String[] args)
          Looks up an MX record by record id.
 void getSOA(String[] args)
          Looks up an SOA record by record id.
 void importAddress(String[] args)
          Imports an A record from a file.
 void match(String[] args)
          Looks up all records for a given domain and any sub domains.
 void matchAName(String[] args)
          Looks up A records for a given host name.
 void matchMX(String[] args)
          Looks up MX records for a given domain.
 void matchSOA(String[] args)
          Looks up SOA records for a given domain.
 void mXImport(String[] args)
          Imports an MX record from a file.
 void removeANAME(String[] args)
          Removes an A record from the configuration service by record id.
 void removeMX(String[] args)
          Removes an MX record from the configuration service by record id.
 void removeSOA(String[] args)
          Removes an SOA record from the configuration service by record id.
 void setConfigurationProxy(org.nhind.config.ConfigurationServiceProxy proxy)
          Sets the printer that will be used to print record query responses.
 void setRecordPrinter(DNSRecordPrinter printer)
          Sets the printer that will be used to print record query responses.
 void sOAImport(String[] args)
          Imports an SOA record from a file.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DNSRecordCommands

public DNSRecordCommands(org.nhind.config.ConfigurationServiceProxy proxy)
Constructor that takes a reference to the configuration service proxy.

Parameters:
proxy - Configuration service proxy for accessing the configuration service.
Since:
1.0
Method Detail

mXImport

public void mXImport(String[] args)
Imports an MX record from a file. The file contains the record in raw DNS wire format.

Parameters:
args - The first entry in the array contains the file path (required).
Since:
1.0

sOAImport

public void sOAImport(String[] args)
Imports an SOA record from a file. The file contains the record in raw DNS wire format.

Parameters:
args - The first entry in the array contains the file path (required).
Since:
1.0

importAddress

public void importAddress(String[] args)
Imports an A record from a file. The file contains the record in raw DNS wire format.

Parameters:
args - The first entry in the array contains the file path (required).
Since:
1.0

addMX

public void addMX(String[] args)
Adds an MX records to the configuration service.

Parameters:
args - Contains the MX record attributes.
Since:
1.0

ensureMX

public void ensureMX(String[] args)
Adds an MX records to the configuration service only if the record does not exist.

Parameters:
args - Contains the MX record attributes.
Since:
1.0

addSOA

public void addSOA(String[] args)
Adds an SOA records to the configuration service.

Parameters:
args - Contains the SOA record attributes.
Since:
1.0

ensureSOA

public void ensureSOA(String[] args)
Adds an SOA records to the configuration service only if the record does not exist.

Parameters:
args - Contains the SOA record attributes.
Since:
1.0

addANAME

public void addANAME(String[] args)
Adds an A records to the configuration service.

Parameters:
args - Contains the A record attributes.
Since:
1.0

ensureANAME

public void ensureANAME(String[] args)
Adds an A records to the configuration service only if the record does not exist.

Parameters:
args - Contains the A record attributes.
Since:
1.0

removeMX

public void removeMX(String[] args)
Removes an MX record from the configuration service by record id.

Parameters:
args - The first entry in the array contains the record id (required).
Since:
1.0

removeSOA

public void removeSOA(String[] args)
Removes an SOA record from the configuration service by record id.

Parameters:
args - The first entry in the array contains the record id (required).
Since:
1.0

removeANAME

public void removeANAME(String[] args)
Removes an A record from the configuration service by record id.

Parameters:
args - The first entry in the array contains the record id (required).
Since:
1.0

getMX

public void getMX(String[] args)
Looks up an MX record by record id.

Parameters:
args - The first entry in the array contains the record id (required).
Since:
1.0

getSOA

public void getSOA(String[] args)
Looks up an SOA record by record id.

Parameters:
args - The first entry in the array contains the record id (required).
Since:
1.0

getANAME

public void getANAME(String[] args)
Looks up an A record by record id.

Parameters:
args - The first entry in the array contains the record id (required).
Since:
1.0

getAll

public void getAll(String[] args)
Retrieves and prints all records in the configuration store.

Parameters:
args - Empty
Since:
1.0

match

public void match(String[] args)
Looks up all records for a given domain and any sub domains.

Parameters:
args - The first entry in the array contains the domain name (required).
Since:
1.0

matchSOA

public void matchSOA(String[] args)
Looks up SOA records for a given domain.

Parameters:
args - The first entry in the array contains the domain name (required).
Since:
1.0

matchAName

public void matchAName(String[] args)
Looks up A records for a given host name.

Parameters:
args - The first entry in the array contains the domain name (required).
Since:
1.0

matchMX

public void matchMX(String[] args)
Looks up MX records for a given domain.

Parameters:
args - The first entry in the array contains the domain name (required).
Since:
1.0

setRecordPrinter

public void setRecordPrinter(DNSRecordPrinter printer)
Sets the printer that will be used to print record query responses.

Parameters:
printer - The printer that will be used to print record query responses.

setConfigurationProxy

public void setConfigurationProxy(org.nhind.config.ConfigurationServiceProxy proxy)
Sets the printer that will be used to print record query responses.

Parameters:
printer - The printer that will be used to print record query responses.


Copyright © 2015. All Rights Reserved.