aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/de/measite/minidns/DNSCache.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/de/measite/minidns/DNSCache.java')
-rw-r--r--src/main/java/de/measite/minidns/DNSCache.java11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/main/java/de/measite/minidns/DNSCache.java b/src/main/java/de/measite/minidns/DNSCache.java
index 78e6c041..14a3a776 100644
--- a/src/main/java/de/measite/minidns/DNSCache.java
+++ b/src/main/java/de/measite/minidns/DNSCache.java
@@ -5,8 +5,19 @@ package de.measite.minidns;
*/
public interface DNSCache {
+ /**
+ * Add an an dns answer/response for a given dns question. Implementations
+ * should honor the ttl / receive timestamp.
+ * @param q The question.
+ * @param message The dns message.
+ */
void put(Question q, DNSMessage message);
+ /**
+ * Request a cached dns response.
+ * @param q The dns question.
+ * @return The dns message.
+ */
DNSMessage get(Question q);
}