private void addCommandMember ( String commandId , CommandGroup group ) { Assert . notNull ( commandId , "commandId" ) ; Assert . notNull ( group , "group" ) ; if ( logger . isDebugEnabled ( ) ) { logger . debug ( "adding command group member with id [" + commandId + "] to group [" + group . getId ( ) + "]" ) ; } AbstractCommand command = null ; if ( getCommandRegistry ( ) != null ) { command = ( AbstractCommand ) getCommandRegistry ( ) . getCommand ( commandId ) ; if ( command != null ) { group . addInternal ( command ) ; } } if ( command == null ) { group . addLazyInternal ( commandId ) ; } }
Adds the command object with the given id to the given command group . If a command registry has not yet been provided to this factory the command id will be passed as a lazy placeholder to the group instead .