Shuyi Chen | d7955ce | 2013-05-22 14:51:55 -0700 | [diff] [blame] | 1 | // Copyright (c) 1999-2004 Brian Wellington (bwelling@xbill.org) |
| 2 | |
| 3 | package org.xbill.DNS; |
| 4 | |
| 5 | import java.util.*; |
| 6 | |
| 7 | /** |
| 8 | * Text - stores text strings |
| 9 | * |
| 10 | * @author Brian Wellington |
| 11 | */ |
| 12 | |
| 13 | public class TXTRecord extends TXTBase { |
| 14 | |
| 15 | private static final long serialVersionUID = -5780785764284221342L; |
| 16 | |
| 17 | TXTRecord() {} |
| 18 | |
| 19 | Record |
| 20 | getObject() { |
| 21 | return new TXTRecord(); |
| 22 | } |
| 23 | |
| 24 | /** |
| 25 | * Creates a TXT Record from the given data |
| 26 | * @param strings The text strings |
| 27 | * @throws IllegalArgumentException One of the strings has invalid escapes |
| 28 | */ |
| 29 | public |
| 30 | TXTRecord(Name name, int dclass, long ttl, List strings) { |
| 31 | super(name, Type.TXT, dclass, ttl, strings); |
| 32 | } |
| 33 | |
| 34 | /** |
| 35 | * Creates a TXT Record from the given data |
| 36 | * @param string One text string |
| 37 | * @throws IllegalArgumentException The string has invalid escapes |
| 38 | */ |
| 39 | public |
| 40 | TXTRecord(Name name, int dclass, long ttl, String string) { |
| 41 | super(name, Type.TXT, dclass, ttl, string); |
| 42 | } |
| 43 | |
| 44 | } |