diff options
| author | abranson <andrew.branson@cern.ch> | 2011-08-02 22:10:28 +0200 |
|---|---|---|
| committer | abranson <andrew.branson@cern.ch> | 2011-08-02 22:10:28 +0200 |
| commit | 5664fd4644c78f4571a1a72e6b9f0511fb10720a (patch) | |
| tree | 7be1c346d1d001bf6b079089f995a60c52b955c1 /source/com/c2kernel/lookup | |
| parent | 29bbf451a22916d39017ec1a3f53f4e0f0e65ee0 (diff) | |
Finished move to generics. Enforced 1.6 compliance for now. No errors or
warnings :)
Diffstat (limited to 'source/com/c2kernel/lookup')
| -rw-r--r--[-rwxr-xr-x] | source/com/c2kernel/lookup/EntityPath.java | 2 | ||||
| -rw-r--r--[-rwxr-xr-x] | source/com/c2kernel/lookup/LDAPPropertyManager.java | 2 | ||||
| -rw-r--r--[-rwxr-xr-x] | source/com/c2kernel/lookup/LDAPRoleManager.java | 4 | ||||
| -rw-r--r--[-rwxr-xr-x] | source/com/c2kernel/lookup/Path.java | 4 | ||||
| -rw-r--r--[-rwxr-xr-x] | source/com/c2kernel/lookup/RolePath.java | 2 |
5 files changed, 7 insertions, 7 deletions
diff --git a/source/com/c2kernel/lookup/EntityPath.java b/source/com/c2kernel/lookup/EntityPath.java index 079f171..3a24228 100755..100644 --- a/source/com/c2kernel/lookup/EntityPath.java +++ b/source/com/c2kernel/lookup/EntityPath.java @@ -127,7 +127,7 @@ public class EntityPath extends Path if (sysKey < 0 || sysKey > maxSysKey)
throw new InvalidEntityPathException("System key "+sysKey+" out of range");
String stringPath = Integer.toString(sysKey);
- ArrayList newKey = new ArrayList();
+ ArrayList<String> newKey = new ArrayList<String>();
for (int i=0; i<elementNo; i++) {
StringBuffer nextComponent = new StringBuffer("d");
int start = stringPath.length()-elementLen;
diff --git a/source/com/c2kernel/lookup/LDAPPropertyManager.java b/source/com/c2kernel/lookup/LDAPPropertyManager.java index 4e1883e..a1fd6af 100755..100644 --- a/source/com/c2kernel/lookup/LDAPPropertyManager.java +++ b/source/com/c2kernel/lookup/LDAPPropertyManager.java @@ -47,7 +47,7 @@ public class LDAPPropertyManager { */
public String[] getPropertyNames(EntityPath thisEntity) throws ObjectNotFoundException {
LDAPEntry entityEntry = LDAPLookupUtils.getEntry(ldap.getConnection(), thisEntity.getFullDN());
- ArrayList propbag = new ArrayList();
+ ArrayList<String> propbag = new ArrayList<String>();
LDAPAttribute props = entityEntry.getAttribute("cristalprop");
for (Enumeration e = props.getStringValues(); e.hasMoreElements();) {
String thisProp = (String)e.nextElement();
diff --git a/source/com/c2kernel/lookup/LDAPRoleManager.java b/source/com/c2kernel/lookup/LDAPRoleManager.java index a9b6b23..a45da13 100755..100644 --- a/source/com/c2kernel/lookup/LDAPRoleManager.java +++ b/source/com/c2kernel/lookup/LDAPRoleManager.java @@ -113,7 +113,7 @@ public class LDAPRoleManager { }
String[] res = LDAPLookupUtils.getAllAttributeValues(roleEntry,"uniqueMember");
- ArrayList agents = new ArrayList();
+ ArrayList<AgentPath> agents = new ArrayList<AgentPath>();
for (int i=0; i<res.length; i++)
{
String userDN = res[i];
@@ -142,7 +142,7 @@ public class LDAPRoleManager { searchCons.setBatchSize(0);
searchCons.setDereference(LDAPSearchConstraints.DEREF_NEVER );
Enumeration roles = mLdap.search(mRolePath,LDAPConnection.SCOPE_SUB,filter,searchCons);
- ArrayList roleList = new ArrayList();
+ ArrayList<RolePath> roleList = new ArrayList<RolePath>();
while(roles.hasMoreElements())
{
diff --git a/source/com/c2kernel/lookup/Path.java b/source/com/c2kernel/lookup/Path.java index b189910..b713493 100755..100644 --- a/source/com/c2kernel/lookup/Path.java +++ b/source/com/c2kernel/lookup/Path.java @@ -124,7 +124,7 @@ public abstract class Path implements Serializable */
public void setPath(String path)
{
- ArrayList newPath = new ArrayList();
+ ArrayList<String> newPath = new ArrayList<String>();
StringTokenizer tok = new StringTokenizer(path, delim);
if (tok.hasMoreTokens()) {
String first = tok.nextToken();
@@ -171,7 +171,7 @@ public abstract class Path implements Serializable if (dn.endsWith(root))
dn = dn.substring(0, dn.lastIndexOf(root));
- ArrayList newPath = new ArrayList();
+ ArrayList<String> newPath = new ArrayList<String>();
StringTokenizer tok = new StringTokenizer(dn, ",");
while (tok.hasMoreTokens()) {
String nextPath = tok.nextToken();
diff --git a/source/com/c2kernel/lookup/RolePath.java b/source/com/c2kernel/lookup/RolePath.java index df26eae..672bdbf 100755..100644 --- a/source/com/c2kernel/lookup/RolePath.java +++ b/source/com/c2kernel/lookup/RolePath.java @@ -63,7 +63,7 @@ public class RolePath extends DomainPath public Enumeration getChildren() {
AgentPath[] agents = getAgentsWithRole();
- Vector children = new Vector(agents.length);
+ Vector<AgentPath> children = new Vector<AgentPath>(agents.length);
for (int i = 0; i < agents.length; i++)
children.add(i, agents[i]);
return children.elements();
|
