Ne.app NeANT
The Ne.app NeANT User module of the NeANT distribution.
Data Structures | Macros | Functions | Variables
25.replace.cpp File Reference
#include <algorithm>
#include <cstring>
#include <rw_alg_test.h>
#include <rw_value.h>
#include <rw_driver.h>
Include dependency graph for 25.replace.cpp:

Go to the source code of this file.

Data Structures

struct  ReplaceTag
 
struct  ReplaceCopyTag
 
struct  NoIterator
 
struct  EqualityPredicate< T, U >
 
class  EqualityPredicate< T, U >::ConvertibleToBool
 

Macros

#define TEST(src, val, new_val)    test_replace (__LINE__, src, val, new_val, it1, it2, (T*)0, pred, tag)
 

Functions

 _RWSTD_NAMESPACE (std)
 
const char * type_name (NoIterator, const UserClass *)
 
template<class Iterator , class T , class Predicate >
void test_replace (int line, const char *src, char val, char new_val, Iterator dummy, NoIterator, const T *, const Predicate *, ReplaceTag tag)
 
template<class Iterator , class OutputIterator , class T , class Predicate >
void test_replace (int line, const char *src, char val, char new_val, Iterator it, OutputIterator dummy, const T *, const Predicate *, ReplaceCopyTag tag)
 
template<class Iterator1 , class Iterator2 , class T , class Predicate , class Tag >
void test_replace (Iterator1 it1, Iterator2 it2, const T *, const Predicate *pred, Tag tag)
 
template<class T , class Predicate , class Tag >
void test_replace (const T *, const Predicate *pred, Tag tag)
 
template<class T >
void test_replace (const T *)
 
template<class InputIterator , class T , class Predicate , class Tag >
void test_replace_copy (const InputIterator &iter, const T *, const Predicate *pred, Tag tag)
 
template<class T , class Predicate , class Tag >
void test_replace_copy (const T *, const Predicate *pred, Tag tag)
 
template<class T >
void test_replace_copy (const T *)
 
int main (int argc, char *argv[])
 

Variables

const char *const fnames [] = { "replace", "replace_copy" }
 
const char *const fnames_if [] = { "replace_if", "replace_copy_if" }
 
int rw_opt_no_replace
 
int rw_opt_no_replace_if
 
int rw_opt_no_replace_copy
 
int rw_opt_no_replace_copy_if
 
int rw_opt_no_input_iter
 
int rw_opt_no_output_iter
 
int rw_opt_no_fwd_iter
 
int rw_opt_no_bidir_iter
 
int rw_opt_no_rnd_iter
 

Macro Definition Documentation

◆ TEST

#define TEST (   src,
  val,
  new_val 
)     test_replace (__LINE__, src, val, new_val, it1, it2, (T*)0, pred, tag)

Function Documentation

◆ _RWSTD_NAMESPACE()

_RWSTD_NAMESPACE ( std  )

25.replace.cpp - test exercising 25.2.4 [lib.alg.replace]

$Id$

Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 1994-2006 Rogue Wave Software.

Definition at line 38 of file 25.replace.cpp.

◆ main()

int main ( int  argc,
char *  argv[] 
)

Definition at line 609 of file 25.replace.cpp.

◆ test_replace() [1/5]

template<class T >
void test_replace ( const T *  )

Definition at line 471 of file 25.replace.cpp.

◆ test_replace() [2/5]

template<class T , class Predicate , class Tag >
void test_replace ( const T *  ,
const Predicate *  pred,
Tag  tag 
)

Definition at line 437 of file 25.replace.cpp.

◆ test_replace() [3/5]

template<class Iterator , class T , class Predicate >
void test_replace ( int  line,
const char *  src,
char  val,
char  new_val,
Iterator  dummy,
NoIterator  ,
const T *  ,
const Predicate *  ,
ReplaceTag  tag 
)

Definition at line 140 of file 25.replace.cpp.

◆ test_replace() [4/5]

template<class Iterator , class OutputIterator , class T , class Predicate >
void test_replace ( int  line,
const char *  src,
char  val,
char  new_val,
Iterator  it,
OutputIterator  dummy,
const T *  ,
const Predicate *  ,
ReplaceCopyTag  tag 
)

Definition at line 251 of file 25.replace.cpp.

◆ test_replace() [5/5]

template<class Iterator1 , class Iterator2 , class T , class Predicate , class Tag >
void test_replace ( Iterator1  it1,
Iterator2  it2,
const T *  ,
const Predicate *  pred,
Tag  tag 
)

Definition at line 366 of file 25.replace.cpp.

◆ test_replace_copy() [1/3]

template<class InputIterator , class T , class Predicate , class Tag >
void test_replace_copy ( const InputIterator &  iter,
const T *  ,
const Predicate *  pred,
Tag  tag 
)

Definition at line 496 of file 25.replace.cpp.

◆ test_replace_copy() [2/3]

template<class T >
void test_replace_copy ( const T *  )

Definition at line 573 of file 25.replace.cpp.

◆ test_replace_copy() [3/3]

template<class T , class Predicate , class Tag >
void test_replace_copy ( const T *  ,
const Predicate *  pred,
Tag  tag 
)

Definition at line 531 of file 25.replace.cpp.

◆ type_name()

const char * type_name ( NoIterator  ,
const UserClass *   
)

Definition at line 96 of file 25.replace.cpp.

Variable Documentation

◆ fnames

const char* const fnames[] = { "replace", "replace_copy" }

Definition at line 79 of file 25.replace.cpp.

◆ fnames_if

const char* const fnames_if[] = { "replace_if", "replace_copy_if" }

Definition at line 80 of file 25.replace.cpp.

◆ rw_opt_no_bidir_iter

int rw_opt_no_bidir_iter

Definition at line 433 of file 25.replace.cpp.

◆ rw_opt_no_fwd_iter

int rw_opt_no_fwd_iter

Definition at line 432 of file 25.replace.cpp.

◆ rw_opt_no_input_iter

int rw_opt_no_input_iter

Definition at line 430 of file 25.replace.cpp.

◆ rw_opt_no_output_iter

int rw_opt_no_output_iter

Definition at line 431 of file 25.replace.cpp.

◆ rw_opt_no_replace

int rw_opt_no_replace

Definition at line 426 of file 25.replace.cpp.

◆ rw_opt_no_replace_copy

int rw_opt_no_replace_copy

Definition at line 428 of file 25.replace.cpp.

◆ rw_opt_no_replace_copy_if

int rw_opt_no_replace_copy_if

Definition at line 429 of file 25.replace.cpp.

◆ rw_opt_no_replace_if

int rw_opt_no_replace_if

Definition at line 427 of file 25.replace.cpp.

◆ rw_opt_no_rnd_iter

int rw_opt_no_rnd_iter

Definition at line 434 of file 25.replace.cpp.