ct_common
1.0.1
Common library for combinatorial testing
|
00001 //===----- ct_common/common/exp_a_sub.cpp -----------------------*- C++ -*-===// 00002 // 00003 // The ct_common Library 00004 // 00005 // This file is distributed under the MIT license. See LICENSE for details. 00006 // 00007 //===----------------------------------------------------------------------===// 00008 // 00009 // This file contains the function definitions of class Exp_A_Sub 00010 // 00011 //===----------------------------------------------------------------------===// 00012 00013 #include <ct_common/common/exp_a_sub.h> 00014 00015 using namespace ct::common; 00016 00017 Exp_A_Sub::Exp_A_Sub(void) 00018 : Exp_A_Binary() { 00019 } 00020 00021 Exp_A_Sub::Exp_A_Sub(const Exp_A_Sub &from) 00022 : Exp_A_Binary(from) { 00023 } 00024 00025 Exp_A_Sub& Exp_A_Sub::operator = (const Exp_A_Sub &right) { 00026 Exp_A_Binary::operator=(right); 00027 return *this; 00028 } 00029 00030 Exp_A_Sub::~Exp_A_Sub(void) { 00031 } 00032 00033 std::string Exp_A_Sub::get_class_name(void) const { 00034 return Exp_A_Sub::class_name(); 00035 } 00036 00037 std::string Exp_A_Sub::class_name(void) { 00038 return "Exp_A_Sub"; 00039 } 00040 00041 int Exp_A_Sub::evaluate_int(int val_1, int val_2) const { 00042 return val_1 - val_2; 00043 } 00044 00045 double Exp_A_Sub::evaluate_double(double val_1, double val_2) const { 00046 return val_1 - val_2; 00047 } 00048 00049 std::string Exp_A_Sub::get_op_token(void) const { 00050 return "-"; 00051 }