1 57 58 package org.apache.commons.discovery.resource.names; 59 60 import org.apache.commons.discovery.ResourceNameDiscover; 61 import org.apache.commons.discovery.ResourceNameListener; 62 63 64 69 public abstract class ResourceNameDiscoverImpl 70 implements ResourceNameDiscover 71 { 72 private ResourceNameListener listener = null; 73 74 protected ResourceNameListener getListener() { 75 return listener; 76 } 77 78 protected boolean notifyListener(String resourceName) { 79 return (listener == null) ? true : listener.found(resourceName); 80 } 81 82 public void setListener(ResourceNameListener listener) { 83 this.listener = listener; 84 } 85 } 86 | Popular Tags |