From 7d47550adc7789dd4f34b3c5994cfce7204b8534 Mon Sep 17 00:00:00 2001 From: Andrew Branson Date: Tue, 17 Jun 2014 09:49:13 +0200 Subject: Remove getChildren methods - all searches should be done by the lookup and the paths should remain data objects. --- src/main/java/com/c2kernel/lookup/Path.java | 12 ------------ 1 file changed, 12 deletions(-) (limited to 'src/main/java/com/c2kernel') diff --git a/src/main/java/com/c2kernel/lookup/Path.java b/src/main/java/com/c2kernel/lookup/Path.java index f9fd15d..d6be37f 100644 --- a/src/main/java/com/c2kernel/lookup/Path.java +++ b/src/main/java/com/c2kernel/lookup/Path.java @@ -12,7 +12,6 @@ package com.c2kernel.lookup; import java.io.Serializable; import java.util.ArrayList; -import java.util.Iterator; import java.util.StringTokenizer; import com.c2kernel.common.ObjectNotFoundException; @@ -201,17 +200,6 @@ public abstract class Path implements Serializable return mSysKey; } - public Path find(String name) throws ObjectNotFoundException { - Iterator e = Gateway.getLookup().search(this, name); - if (e.hasNext()) { - Path thisPath = e.next(); - if (e.hasNext()) - throw new ObjectNotFoundException("More than one match for "+name, ""); - return thisPath; - } - throw new ObjectNotFoundException("No match for "+name, ""); - } - public abstract ItemPath getEntity() throws ObjectNotFoundException; @Override -- cgit v1.2.3