public class RRset extends Object implements Serializable
Record,
RRSIGRecord,
Serialized Form| Constructor and Description |
|---|
RRset()
Creates an empty RRset
|
RRset(Record... records)
Creates an RRset and sets its contents to the specified record(s)
|
RRset(Record record)
Creates an RRset and sets its contents to the specified record
|
RRset(RRset rrset)
Creates an RRset with the contents of an existing RRset
|
| Modifier and Type | Method and Description |
|---|---|
void |
addRR(Record r)
Adds a Record to this RRset.
|
void |
addRR(RRSIGRecord r)
Adds a signature to this RRset.
|
protected boolean |
canEqual(Object other) |
void |
clear()
Deletes all records (including signatures) from this RRset
|
void |
deleteRR(Record r)
Deletes a record from this RRset
|
void |
deleteRR(RRSIGRecord r)
Deletes a signature from this RRset
|
boolean |
equals(Object o) |
Record |
first()
Returns the first record in this RRset, either an RR or a signature.
|
int |
getDClass()
Returns the class of the records
|
Name |
getName()
Returns the name of the records
|
long |
getTTL()
Returns the ttl of the records
|
int |
getType()
Returns the type of the records
|
int |
hashCode() |
List<Record> |
rrs()
Returns a list of all data records.
|
List<Record> |
rrs(boolean cycle)
Returns a list of all data records.
|
List<RRSIGRecord> |
sigs()
Returns a list of all signature records.
|
int |
size()
Returns the number of (data) records
|
String |
toString()
Converts the RRset to a String
|
public RRset()
public RRset(Record record)
public RRset(Record... records)
records - The records to add to the set. See addRR(Record) for restrictions.public RRset(RRset rrset)
public void addRR(RRSIGRecord r)
IllegalArgumentException - if the RRset already contains records and the signature to add
does not match.public void addRR(Record r)
IllegalArgumentException - if the RRset already contains records and the record to add
does not match.public void deleteRR(RRSIGRecord r)
public void deleteRR(Record r)
public void clear()
public List<Record> rrs(boolean cycle)
cycle - If true, cycle through the records so that each list will start with a different
record.public List<Record> rrs()
public List<RRSIGRecord> sigs()
public int size()
public int getType()
Typepublic int getDClass()
DClasspublic long getTTL()
public Record first()
IllegalStateException - if the RRset is emptypublic String toString()
protected boolean canEqual(Object other)
Copyright © 2021 dnsjava.org. All rights reserved.