use of alma.ACS.PropertyOperations in project ACS by ACS-Community.
the class CharacteristicComponentImpl method initialize.
/**
* @see alma.acs.component.ComponentLifecycle#initialize(alma.acs.container.ContainerServices)
*/
public void initialize(ContainerServices containerServices) throws ComponentLifecycleException {
super.initialize(containerServices);
try {
DAL dal = m_containerServices.getCDB();
// create characteristic model
// TODO think of error handling; why creating model per instance...
characteristicModelImpl = new CharacteristicModelImpl("alma/" + m_instanceName, dal);
} catch (AcsJContainerServicesEx ce) {
throw new ComponentLifecycleException("Failed to create characteristic model.", ce);
}
// create properties list
properties = new HashMap<PropertyOperations, Servant>();
}
use of alma.ACS.PropertyOperations in project ACS by ACS-Community.
the class CharacteristicComponentImpl method descriptor.
/*********************** [ CharacteristicComponent ] ***********************/
/**
* NOTE: <code>characteristic_component_ref</code> member of <code>CharacteristicComponentDesc</code> is always set to <code>null</code>.
* @see alma.ACS.CharacteristicComponentOperations#descriptor()
*/
public CharacteristicComponentDesc descriptor() {
if (characteristicComponentDesc == null) {
PropertyDesc[] propertyDescriptors = null;
synchronized (properties) {
int i = 0;
propertyDescriptors = new PropertyDesc[properties.size()];
Iterator<PropertyOperations> iter = properties.keySet().iterator();
while (iter.hasNext()) propertyDescriptors[i++] = ((PropertyImpl) iter.next()).getPropertyDescriptor();
}
// TODO CORBA reference to this component to be set
characteristicComponentDesc = new CharacteristicComponentDesc(null, m_instanceName, propertyDescriptors, get_all_characteristics());
}
return characteristicComponentDesc;
}
Aggregations