original_string: protected function _fromSequenceString($str)
      {
          $ids = array();
          $str = trim($str);
  
          if (!strlen($str)) {
              return $ids;
          }
  
          $idarray = explode(',', $str);
  
          foreach ($idarray as $val) {
              $range = explode(':', $val);
              if (isset($range[1])) {
                  for ($i = min($range), $j = max($range); $i <= $j; ++$i) {
                      $ids[] = $i;
                  }
              } else {
                  $ids[] = $val;
              }
          }
  
          return $ids;
      }
code: protected function _fromSequenceString($str)
      {
          $ids = array();
          $str = trim($str);
  
          if (!strlen($str)) {
              return $ids;
          }
  
          $idarray = explode(',', $str);
  
          foreach ($idarray as $val) {
              $range = explode(':', $val);
              if (isset($range[1])) {
                  for ($i = min($range), $j = max($range); $i <= $j; ++$i) {
                      $ids[] = $i;
                  }
              } else {
                  $ids[] = $val;
              }
          }
  
          return $ids;
      }
code_tokens: protected function _fromSequenceString ( $ str ) { $ ids = array ( ) ; $ str = trim ( $ str ) ; if ( ! strlen ( $ str ) ) { return $ ids ; } $ idarray = explode ( ',' , $ str ) ; foreach ( $ idarray as $ val ) { $ range = explode ( ':' , $ val ) ; if ( isset ( $ range [ 1 ] ) ) { for ( $ i = min ( $ range ) , $ j = max ( $ range ) ; $ i <= $ j ; ++ $ i ) { $ ids [ ] = $ i ; } } else { $ ids [ ] = $ val ; } } return $ ids ; }
docstring: Parse an IMAP message sequence string into a list of indices.
  
  @see _toSequenceString()
  
  @param string $str  The IMAP message sequence string.
  
  @return array  An array of indices.
docstring_tokens: Parse an IMAP message sequence string into a list of indices .