public <T> T getExtensor(Class<T> cls) { if (delegate != null) { return delegate.getExtensor(cls); } Object[] exts = extensors.get(); if (exts == null) { return null; } for (int x = 0; x < exts.length; x++) { if (cls.isInstance(exts[x])) { return cls.cast(exts[x]); } } return null; } public <T> List<T> getExtensors(Class<T> cls) {
public <T> T getExtensor(Class<T> cls) { if (delegate != null) { return delegate.getExtensor(cls); } Object exts[] = extensors.get(); if (exts == null) { return null; } for (int x = 0; x < exts.length; x++) { if (cls.isInstance(exts[x])) { return cls.cast(exts[x]); } } return null; } public <T> List<T> getExtensors(Class<T> cls) {
public <T> T getExtensor(Class<T> cls) { if (delegate != null) { return delegate.getExtensor(cls); } Object exts[] = extensors.get(); if (exts == null) { return null; } for (int x = 0; x < exts.length; x++) { if (cls.isInstance(exts[x])) { return cls.cast(exts[x]); } } return null; } public <T> List<T> getExtensors(Class<T> cls) {
public <T> T getExtensor(Class<T> cls) { if (delegate != null) { return delegate.getExtensor(cls); } Object[] exts = extensors.get(); if (exts == null) { return null; } for (int x = 0; x < exts.length; x++) { if (cls.isInstance(exts[x])) { return cls.cast(exts[x]); } } return null; } public <T> List<T> getExtensors(Class<T> cls) {
/** * Lookup a configuration value. This may be found in the properties holder supplied * (i.e. an EndpointInfo or ServiceInfo), or it may be a property on the Bus itself. * If no value is found, the defaultValue is returned. * * @param defaultValue the default value * @param type the extensor type * @return the configuration value or the default */ public <T> T getTraversedExtensor(T defaultValue, Class<T> type) { if (delegate != null) { return delegate.getTraversedExtensor(defaultValue, type); } T extensor = getExtensor(type); if (extensor == null) { return defaultValue; } return extensor; }
/** * Lookup a configuration value. This may be found in the properties holder supplied * (i.e. an EndpointInfo or ServiceInfo), or it may be a property on the Bus itself. * If no value is found, the defaultValue is returned. * * @param defaultValue the default value * @param type the extensor type * @return the configuration value or the default */ public <T> T getTraversedExtensor(T defaultValue, Class<T> type) { if (delegate != null) { return delegate.getTraversedExtensor(defaultValue, type); } T extensor = getExtensor(type); if (extensor == null) { return defaultValue; } return extensor; }
/** * Lookup a configuration value. This may be found in the properties holder supplied * (i.e. an EndpointInfo or ServiceInfo), or it may be a property on the Bus itself. * If no value is found, the defaultValue is returned. * * @param defaultValue the default value * @param type the extensor type * @return the configuration value or the default */ public <T> T getTraversedExtensor(T defaultValue, Class<T> type) { if (delegate != null) { return delegate.getTraversedExtensor(defaultValue, type); } T extensor = getExtensor(type); if (extensor == null) { return defaultValue; } return extensor; }
/** * Lookup a configuration value. This may be found in the properties holder supplied * (i.e. an EndpointInfo or ServiceInfo), or it may be a property on the Bus itself. * If no value is found, the defaultValue is returned. * * @param defaultValue the default value * @param type the extensor type * @return the configuration value or the default */ public <T> T getTraversedExtensor(T defaultValue, Class<T> type) { if (delegate != null) { return delegate.getTraversedExtensor(defaultValue, type); } T extensor = getExtensor(type); if (extensor == null) { return defaultValue; } return extensor; }