org.xbill.DNS
Class TXTRecord
java.lang.Object
org.xbill.DNS.Record
org.xbill.DNS.TXTRecord
- All Implemented Interfaces:
- Cloneable, Comparable
public class TXTRecord
- extends Record
Text - stores text strings
- Author:
- Brian Wellington
Constructor Summary |
TXTRecord(Name name,
int dclass,
long ttl,
List strings)
Creates a TXT Record from the given data |
TXTRecord(Name name,
int dclass,
long ttl,
String string)
Creates a TXT Record from the given data |
Methods inherited from class org.xbill.DNS.Record |
byteArrayFromString, byteArrayToString, compareTo, equals, fromString, fromString, fromWire, getAdditionalName, getDClass, getName, getRRsetType, getTTL, getType, hashCode, newRecord, newRecord, newRecord, newRecord, rdataToString, rdataToWireCanonical, sameRRset, toString, toWire, toWireCanonical, unknownToString, withName |
strings
protected List strings
TXTRecord
public TXTRecord(Name name,
int dclass,
long ttl,
List strings)
- Creates a TXT Record from the given data
- Parameters:
strings
- The text strings
- Throws:
IllegalArgumentException
- One of the strings has invalid escapes
TXTRecord
public TXTRecord(Name name,
int dclass,
long ttl,
String string)
- Creates a TXT Record from the given data
- Parameters:
string
- One text string
- Throws:
IllegalArgumentException
- The string has invalid escapes
getStrings
public List getStrings()
- Returns the text strings
- Returns:
- A list of Strings corresponding to the text strings.
getStringsAsByteArrays
public List getStringsAsByteArrays()
- Returns the text strings
- Returns:
- A list of byte arrays corresponding to the text strings.