From 41e72531b209b74571589296a3a33354eb2a1c39 Mon Sep 17 00:00:00 2001
From: Matthew Swift <matthew.swift@forgerock.com>
Date: Tue, 03 Jan 2012 17:05:22 +0000
Subject: [PATCH] Fix OPENDJ-394: Do not declare unchecked exceptions in method declarations
---
opendj3/opendj-ldap-sdk/src/main/java/org/forgerock/opendj/ldap/LinkedHashMapEntry.java | 12 +++++-------
1 files changed, 5 insertions(+), 7 deletions(-)
diff --git a/opendj3/opendj-ldap-sdk/src/main/java/org/forgerock/opendj/ldap/LinkedHashMapEntry.java b/opendj3/opendj-ldap-sdk/src/main/java/org/forgerock/opendj/ldap/LinkedHashMapEntry.java
index c425db3..f900a06 100644
--- a/opendj3/opendj-ldap-sdk/src/main/java/org/forgerock/opendj/ldap/LinkedHashMapEntry.java
+++ b/opendj3/opendj-ldap-sdk/src/main/java/org/forgerock/opendj/ldap/LinkedHashMapEntry.java
@@ -23,6 +23,7 @@
*
*
* Copyright 2010 Sun Microsystems, Inc.
+ * Portions copyright 2012 ForgeRock AS.
*/
package org.forgerock.opendj.ldap;
@@ -31,7 +32,7 @@
import java.util.LinkedHashMap;
-import org.forgerock.i18n.LocalizedIllegalArgumentException;
+import org.forgerock.i18n.*;
import org.forgerock.opendj.ldap.requests.Requests;
import com.forgerock.opendj.util.Validator;
@@ -61,7 +62,7 @@
*/
public static final EntryFactory FACTORY = new EntryFactory()
{
- public Entry newEntry(final DN name) throws NullPointerException
+ public Entry newEntry(final DN name)
{
return new LinkedHashMapEntry(name);
}
@@ -85,7 +86,6 @@
* @see #LinkedHashMapEntry(Entry)
*/
public static LinkedHashMapEntry deepCopyOfEntry(final Entry entry)
- throws NullPointerException
{
LinkedHashMapEntry copy = new LinkedHashMapEntry(entry.getName());
for (final Attribute attribute : entry.getAllAttributes())
@@ -116,7 +116,7 @@
* @throws NullPointerException
* If {@code name} was {@code null}.
*/
- public LinkedHashMapEntry(final DN name) throws NullPointerException
+ public LinkedHashMapEntry(final DN name)
{
super(Validator.ensureNotNull(name),
new LinkedHashMap<AttributeDescription, Attribute>());
@@ -137,7 +137,7 @@
* If {@code entry} was {@code null}.
* @see #deepCopyOfEntry(Entry)
*/
- public LinkedHashMapEntry(final Entry entry) throws NullPointerException
+ public LinkedHashMapEntry(final Entry entry)
{
this(entry.getName());
for (final Attribute attribute : entry.getAllAttributes())
@@ -160,7 +160,6 @@
* If {@code name} was {@code null}.
*/
public LinkedHashMapEntry(final String name)
- throws LocalizedIllegalArgumentException, NullPointerException
{
this(DN.valueOf(name));
}
@@ -181,7 +180,6 @@
* If {@code ldifLines} was {@code null} .
*/
public LinkedHashMapEntry(final String... ldifLines)
- throws LocalizedIllegalArgumentException, NullPointerException
{
this(Requests.newAddRequest(ldifLines));
}
--
Gitblit v1.10.0