From a89f7014aeb71dba5c94404dfea7eb89e7eeee74 Mon Sep 17 00:00:00 2001
From: Jean-Noel Rouvignac <jean-noel.rouvignac@forgerock.com>
Date: Wed, 08 Jul 2015 06:48:02 +0000
Subject: [PATCH] AutoRefactor'ed Use Diamond Operator
---
opendj-server-legacy/src/main/java/org/opends/server/schema/ObjectClassSyntax.java | 19 +++++++++----------
1 files changed, 9 insertions(+), 10 deletions(-)
diff --git a/opendj-server-legacy/src/main/java/org/opends/server/schema/ObjectClassSyntax.java b/opendj-server-legacy/src/main/java/org/opends/server/schema/ObjectClassSyntax.java
index 4d0e146..4372579 100644
--- a/opendj-server-legacy/src/main/java/org/opends/server/schema/ObjectClassSyntax.java
+++ b/opendj-server-legacy/src/main/java/org/opends/server/schema/ObjectClassSyntax.java
@@ -287,16 +287,15 @@
// we get to the end of the value. But before we start, set default values
// for everything else we might need to know.
String primaryName = oid;
- List<String> names = new LinkedList<String>();
+ List<String> names = new LinkedList<>();
String description = null;
boolean isObsolete = false;
- Set<AttributeType> requiredAttributes = new LinkedHashSet<AttributeType>();
- Set<AttributeType> optionalAttributes = new LinkedHashSet<AttributeType>();
- Set<ObjectClass> superiorClasses = new LinkedHashSet<ObjectClass>();
+ Set<AttributeType> requiredAttributes = new LinkedHashSet<>();
+ Set<AttributeType> optionalAttributes = new LinkedHashSet<>();
+ Set<ObjectClass> superiorClasses = new LinkedHashSet<>();
//Default OC Type is STRUCTURAL ( RFC 4512 4.1.1)
ObjectClassType objectClassType = ObjectClassType.STRUCTURAL;
- Map<String, List<String>> extraProperties =
- new LinkedHashMap<String, List<String>>();
+ Map<String, List<String>> extraProperties = new LinkedHashMap<>();
while (true)
@@ -459,7 +458,7 @@
// by one or more names separated by spaces and the dollar sign
// character, followed by a closing parenthesis.
c = valueStr.charAt(pos++);
- LinkedList<ObjectClass> listSupOCs = new LinkedList<ObjectClass>();
+ LinkedList<ObjectClass> listSupOCs = new LinkedList<>();
if(c == '(')
{
while(true)
@@ -549,7 +548,7 @@
}
else if (lowerTokenName.equals("must"))
{
- LinkedList<AttributeType> attrs = new LinkedList<AttributeType>();
+ LinkedList<AttributeType> attrs = new LinkedList<>();
// This specifies the set of required attributes for the objectclass.
// It may be a single name or OID (not in quotes), or it may be an
@@ -634,7 +633,7 @@
}
else if (lowerTokenName.equals("may"))
{
- LinkedList<AttributeType> attrs = new LinkedList<AttributeType>();
+ LinkedList<AttributeType> attrs = new LinkedList<>();
// This specifies the set of optional attributes for the objectclass.
// It may be a single name or OID (not in quotes), or it may be an
@@ -723,7 +722,7 @@
// either a single value in single quotes or an open parenthesis
// followed by one or more values in single quotes separated by spaces
// followed by a close parenthesis.
- List<String> valueList = new LinkedList<String>();
+ List<String> valueList = new LinkedList<>();
pos = readExtraParameterValues(valueStr, valueList, pos);
extraProperties.put(tokenName, valueList);
}
--
Gitblit v1.10.0