if (managedObject instanceof ManagedCamelContext) {
ManagedCamelContext mcc = (ManagedCamelContext) managedObject;
objectName = getManagementNamingStrategy().getObjectNameForCamelContext(mcc.getContext());
} else if (managedObject instanceof ManagedComponent) {
ManagedComponent mc = (ManagedComponent) managedObject;
objectName = getManagementNamingStrategy().getObjectNameForComponent(mc.getComponent(), mc.getComponentName());
} else if (managedObject instanceof ManagedEndpoint) {
ManagedEndpoint me = (ManagedEndpoint) managedObject;
objectName = getManagementNamingStrategy().getObjectNameForEndpoint(me.getEndpoint());
} else if (managedObject instanceof Endpoint) {
objectName = getManagementNamingStrategy().getObjectNameForEndpoint((Endpoint) managedObject);