Methods Summary |
---|
public void | addProperty(ResourceProperty property)
properties_.put(property.getName(), property);
|
protected abstract J2EEResource | doClone(java.lang.String name)
|
public java.lang.String | getDescription()
return description_;
|
public java.lang.String | getName()
return name_;
|
public java.util.Set | getProperties()
Set shallowCopy = new HashSet();
Collection collection = properties_.values();
for(Iterator iter = collection.iterator(); iter.hasNext();) {
ResourceProperty next = (ResourceProperty) iter.next();
shallowCopy.add(next);
}
return shallowCopy;
|
public ResourceProperty | getProperty(java.lang.String propertyName)
return (ResourceProperty) properties_.get(propertyName);
|
protected java.lang.String | getPropsString()
StringBuffer propsBuffer = new StringBuffer();
Set props = getProperties();
if( !props.isEmpty() ) {
for(Iterator iter = props.iterator(); iter.hasNext(); ) {
if( propsBuffer.length() == 0 ) {
propsBuffer.append("[ ");
} else {
propsBuffer.append(" , ");
}
ResourceProperty next = (ResourceProperty) iter.next();
propsBuffer.append(next.getName() + "=" + next.getValue());
}
propsBuffer.append(" ]");
}
return propsBuffer.toString();
|
public abstract int | getType()
|
public boolean | isEnabled()
return enabled_;
|
public J2EEResource | makeClone(java.lang.String name)
J2EEResource clone = doClone(name);
Set entrySet = properties_.entrySet();
for(Iterator iter = entrySet.iterator(); iter.hasNext();) {
Map.Entry next = (Map.Entry) iter.next();
ResourceProperty nextProp = (ResourceProperty) next.getValue();
ResourceProperty propClone =
new ResourcePropertyImpl((String) next.getKey());
propClone.setValue(next.getValue());
clone.addProperty(propClone);
}
// START OF IASRI #4626188
clone.setEnabled(isEnabled());
clone.setDescription(getDescription());
// END OF IASRI #4626188
return clone;
|
public boolean | removeProperty(ResourceProperty property)
Object removedObj = properties_.remove(property.getName());
return (removedObj != null);
|
public void | setDescription(java.lang.String value)
description_ = value;
|
public void | setEnabled(boolean value)
enabled_ = value;
|