aboutsummaryrefslogtreecommitdiffstats
path: root/asm
diff options
context:
space:
mode:
authoraclement <aclement>2008-11-03 23:53:57 +0000
committeraclement <aclement>2008-11-03 23:53:57 +0000
commitf357106f919d38b45e4477fc8165cdeaf80c640e (patch)
treef6eeac55e160854744f972893f1c510ae7cb39a1 /asm
parenta6ab11f0bbbd8810d05bbbf055ef2699116f7846 (diff)
downloadaspectj-f357106f919d38b45e4477fc8165cdeaf80c640e.tar.gz
aspectj-f357106f919d38b45e4477fc8165cdeaf80c640e.zip
Make findElementForHandleOrCreate public
Diffstat (limited to 'asm')
-rw-r--r--asm/src/org/aspectj/asm/IHierarchy.java5
-rw-r--r--asm/src/org/aspectj/asm/internal/AspectJElementHierarchy.java2
2 files changed, 3 insertions, 4 deletions
diff --git a/asm/src/org/aspectj/asm/IHierarchy.java b/asm/src/org/aspectj/asm/IHierarchy.java
index 740c8f772..e1f3dded9 100644
--- a/asm/src/org/aspectj/asm/IHierarchy.java
+++ b/asm/src/org/aspectj/asm/IHierarchy.java
@@ -43,11 +43,10 @@ public interface IHierarchy extends Serializable {
public boolean isValid();
- /**
- * @return null if not found
- */
public IProgramElement findElementForHandle(String handle);
+ public IProgramElement findElementForHandleOrCreate(String handle, boolean create);
+
/**
* Returns the first match
*
diff --git a/asm/src/org/aspectj/asm/internal/AspectJElementHierarchy.java b/asm/src/org/aspectj/asm/internal/AspectJElementHierarchy.java
index 089938674..5443e759f 100644
--- a/asm/src/org/aspectj/asm/internal/AspectJElementHierarchy.java
+++ b/asm/src/org/aspectj/asm/internal/AspectJElementHierarchy.java
@@ -422,7 +422,7 @@ public class AspectJElementHierarchy implements IHierarchy {
// TODO: optimize this lookup
// only want to create a file node if can't find the IPE if called through
// findElementForHandle() to mirror behaviour before pr141730
- private IProgramElement findElementForHandleOrCreate(String handle, boolean create) {
+ public IProgramElement findElementForHandleOrCreate(String handle, boolean create) {
// try the cache first...
IProgramElement ipe = (IProgramElement) handleMap.get(handle);
if (ipe != null) {