- 2.73.0 (latest)
- 2.72.0
- 2.71.0
- 2.70.0
- 2.68.0
- 2.66.0
- 2.65.0
- 2.62.0
- 2.61.0
- 2.60.0
- 2.58.0
- 2.57.0
- 2.56.0
- 2.55.0
- 2.54.0
- 2.53.0
- 2.52.0
- 2.51.0
- 2.50.0
- 2.49.0
- 2.47.0
- 2.46.0
- 2.45.0
- 2.44.0
- 2.43.0
- 2.42.0
- 2.41.0
- 2.40.0
- 2.39.0
- 2.38.0
- 2.37.0
- 2.35.0
- 2.34.0
- 2.33.0
- 2.32.0
- 2.31.0
- 2.30.0
- 2.29.0
- 2.28.0
- 2.27.0
- 2.26.0
- 2.25.0
- 2.22.0
- 2.21.0
- 2.20.0
- 2.19.0
- 2.18.0
- 2.17.0
- 2.16.0
- 2.15.0
- 2.14.0
- 2.13.0
- 2.12.0
- 2.11.0
- 2.10.0
- 2.9.0
- 2.7.0
- 2.6.0
- 2.5.0
- 2.4.0
- 2.3.0
- 2.2.0
- 2.1.8
- 2.0.9
public static class RecordSet.Builder
A builder for RecordSet.
Methods
addRecord(String record)
public RecordSet.Builder addRecord(String record)
Adds a record to the record set. The records should be as defined in RFC 1035 (section 5) and RFC 1034 (section 3.6.1). Examples of records are available in Google DNS documentation. See Also: Google DNS documentation
Name | Description |
record |
String |
Type | Description |
RecordSet.Builder |
build()
public RecordSet build()
Builds the record set.
Type | Description |
RecordSet |
clearRecords()
public RecordSet.Builder clearRecords()
Removes all the records.
Type | Description |
RecordSet.Builder |
removeRecord(String record)
public RecordSet.Builder removeRecord(String record)
Removes a record from the set. An exact match is required.
Name | Description |
record |
String |
Type | Description |
RecordSet.Builder |
setName(String name)
public RecordSet.Builder setName(String name)
Sets the name for this record set. For example, www.example.com.
Name | Description |
name |
String |
Type | Description |
RecordSet.Builder |
setRecords(List<String> records)
public RecordSet.Builder setRecords(List<String> records)
Replaces the current records with the provided list of records.
Name | Description |
records |
List<String> |
Type | Description |
RecordSet.Builder |
setTtl(int duration, TimeUnit unit)
public RecordSet.Builder setTtl(int duration, TimeUnit unit)
Sets the time that this record can be cached by resolvers. This number must be non-negative. The maximum duration must be equivalent to at most Integer#MAX_VALUE seconds.
Name | Description |
duration |
int A non-negative number of time units |
unit |
TimeUnit The unit of the ttl parameter |
Type | Description |
RecordSet.Builder |
setType(RecordSet.Type type)
public RecordSet.Builder setType(RecordSet.Type type)
The identifier of a supported record type, for example, A, AAAA, MX, TXT, and so on.
Name | Description |
type |
RecordSet.Type |
Type | Description |
RecordSet.Builder |