01: // Copyright (c) 1999-2004 Brian Wellington (bwelling@xbill.org)
02:
03: package org.xbill.DNS;
04:
05: /**
06: * Name Server Record - contains the name server serving the named zone
07: *
08: * @author Brian Wellington
09: */
10:
11: public class NSRecord extends SingleCompressedNameBase {
12:
13: NSRecord() {
14: }
15:
16: Record getObject() {
17: return new NSRecord();
18: }
19:
20: /**
21: * Creates a new NS Record with the given data
22: * @param target The name server for the given domain
23: */
24: public NSRecord(Name name, int dclass, long ttl, Name target) {
25: super (name, Type.NS, dclass, ttl, target, "target");
26: }
27:
28: /** Gets the target of the NS Record */
29: public Name getTarget() {
30: return getSingleName();
31: }
32:
33: public Name getAdditionalName() {
34: return getSingleName();
35: }
36:
37: }
|