directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From erodrig...@apache.org
Subject svn commit: r125017 - /incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/QuestionRecord.java /incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/ResourceRecord.java
Date Thu, 13 Jan 2005 02:05:31 GMT
Author: erodriguez
Date: Wed Jan 12 18:05:30 2005
New Revision: 125017

URL: http://svn.apache.org/viewcvs?view=rev&rev=125017
Log:
Update to Record types to allow for encoding.
Modified:
   incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/QuestionRecord.java
   incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/ResourceRecord.java

Modified: incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/QuestionRecord.java
Url: http://svn.apache.org/viewcvs/incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/QuestionRecord.java?view=diff&rev=125017&p1=incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/QuestionRecord.java&r1=125016&p2=incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/QuestionRecord.java&r2=125017
==============================================================================
--- incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/QuestionRecord.java
(original)
+++ incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/QuestionRecord.java
Wed Jan 12 18:05:30 2005
@@ -18,6 +18,7 @@
 package org.apache.dns.records;
 
 
+
 /**
  * The question section is used to carry the "question" in most queries,
  * i.e., the parameters that define what is being asked.  The section

Modified: incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/ResourceRecord.java
Url: http://svn.apache.org/viewcvs/incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/ResourceRecord.java?view=diff&rev=125017&p1=incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/ResourceRecord.java&r1=125016&p2=incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/ResourceRecord.java&r2=125017
==============================================================================
--- incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/ResourceRecord.java
(original)
+++ incubator/directory/dns/trunk/core/src/java/org/apache/dns/records/ResourceRecord.java
Wed Jan 12 18:05:30 2005
@@ -64,6 +64,46 @@
 		this.resourceData = resourceData;
 	}
 	
+	/**
+	 * @return Returns the domain name.
+	 */
+	public String getDomainName()
+	{
+		return domainName;
+	}
+	
+	/**
+	 * @return Returns the record type.
+	 */
+	public RecordType getRecordType()
+	{
+		return recordType;
+	}
+	
+	/**
+	 * @return Returns the record class.
+	 */
+	public RecordClass getRecordClass()
+	{
+		return recordClass;
+	}
+	
+	/**
+	 * @return Returns the resource data length.
+	 */
+	public int getResourceDataLength()
+	{
+		return resourceData.length;
+	}
+	
+	/**
+	 * @return Returns the time-to-live (TTL).
+	 */
+	public int getTimeToLive()
+	{
+		return timeToLive;
+	}
+	
 	abstract protected void dataToByteBuffer( ByteBuffer out );
 	
 	public void writeTo( ByteBuffer out )
@@ -73,7 +113,7 @@
 	
 	public String toString()
 	{
-		return "org.apache.dns.records.ResourceRecord[ " + domainName + " ( " +
+		return getClass().getName() + "[ " + domainName + " ( " +
 				recordClass + " " + recordType + " " + timeToLive + " " +
 				resourceData.length + " ) ]";
 	}

Mime
View raw message