ATerm++

PrevUpHomeNext

Class aterm_list

genspect::aterm_list —

Synopsis

class aterm_list : public genspect::aterm {
public:
  // types
  typedef aterm               value_type;     
  typedef aterm *             pointer;        
  typedef aterm &             reference;      
  typedef const aterm         const_reference;
  typedef size_t              size_type;      
  typedef ptrdiff_t           difference_type;
  typedef aterm_list_iterator iterator;       
  typedef aterm_list_iterator const_iterator; 

  // construct/copy/destruct
  aterm_list();
  aterm_list(ATermList);
  template<typename Iter> aterm_list(Iter, Iter);

  // public member functions
  const_iterator begin() const;
  const_iterator end() const;
  size_type size();
  size_type max_size();
  bool empty() const;
  void swap(aterm_list &);
  aterm front() const;
  const_iterator previous(const_iterator) const;
  void clear();
  operator ATermList() const;
  ATermList list() const;
};

Description

aterm_list construct/copy/destruct

  1. aterm_list();

    Creates an empty aterm_list.

  2. aterm_list(ATermList l);

    The copy constructor.

  3. template<typename Iter> aterm_list(Iter first, Iter last);

    Creates an aterm_list with a copy of a range.

aterm_list public member functions

  1. const_iterator begin() const;

    Returns an iterator pointing to the end of the aterm_list.

  2. const_iterator end() const;

    Returns a const_iterator pointing to the beginning of the aterm_list.

  3. size_type size();

    Returns the size of the aterm_list.

  4. size_type max_size();

    Returns the largest possible size of the aterm_list.

  5. bool empty() const;

    true if the list's size is 0.

  6. void swap(aterm_list & l);

    Swaps the contents of two aterm_lists.

  7. aterm front() const;

    Returns the first element.

  8. const_iterator previous(const_iterator pos) const;

    pos must be a valid iterator in *this. The return value is an iterator prev such that ++prev == pos. Complexity: linear in the number of iterators in the range [begin(), pos).

  9. void clear();

    Erases all of the elements.

  10. operator ATermList() const;

    Conversion to ATermList.

  11. ATermList list() const;

    Returns the ATermList that is contained by the aterm_list.

Copyright © 2004 Wieger Wesselink

PrevUpHomeNext