code: CommandJdo asUserInitiatedCommandJdo(final Command command) {
          if(!(command instanceof CommandJdo)) {
              // ought not to be the case, since this service created the object in the #create() method
              return null;
          }
          if(command.getExecuteIn() != ExecuteIn.FOREGROUND) {
              return null;
          } 
          final CommandJdo commandJdo = (CommandJdo) command;
          return commandJdo.shouldPersist()? commandJdo: null;
      }
docs: Not API, also used by {@link CommandServiceJdoRepository}.