code: protected void bindAllRemoteInterfacesToContextRoot() {
          final boolean isTraceOn = TraceComponent.isAnyTracingEnabled();
          if (isTraceOn && tc.isEntryEnabled())
              Tr.entry(tc, "bindAllRemoteInterfacesToContextRoot");
  
          Map<EJBModuleMetaDataImpl, NameSpaceBinder<?>> binders = new HashMap<EJBModuleMetaDataImpl, NameSpaceBinder<?>>();
  
          // Start with the list of all HomeRecords. Not all of these beans may have
          // started, but this is the complete set of everything that would have been
          // bound into some naming context. The container may not be available yet
          // if the EJB feature is just starting, but then there is nothing to do.
          HomeOfHomes homeOfHomes = (ivContainer != null) ? ivContainer.getHomeOfHomes() : null;
          if (homeOfHomes != null) {
              List<HomeRecord> hrs = ivContainer.getHomeOfHomes().getAllHomeRecords();
  
              for (HomeRecord hr : hrs) {
                  if (hr.bindToContextRoot()) {
                      BeanMetaData bmd = hr.getBeanMetaData();
  
                      if (isTraceOn && tc.isDebugEnabled())
                          Tr.debug(tc, "processing bindings for " + bmd.j2eeName);
  
                      if (bmd.homeInterfaceClassName != null) {
                          bindRemoteInterfaceToContextRoot(binders, hr, bmd.homeInterfaceClassName, -1);
                      }
  
                      if (bmd.ivBusinessRemoteInterfaceClassNames != null) {
                          int interfaceIndex = 0;
                          for (String remoteInterfaceName : bmd.ivBusinessRemoteInterfaceClassNames) {
                              bindRemoteInterfaceToContextRoot(binders, hr, remoteInterfaceName, interfaceIndex++);
                          }
                      }
                  }
              }
          }
          if (isTraceOn && tc.isEntryEnabled())
              Tr.exit(tc, "bindAllRemoteInterfacesToContextRoot");
      }
docs: Bind the remote interfaces for all beans known to the container.
  
  Intended to be used to restore EJB bindings when the ORB is restarted.