Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

boxes_delta.h

Go to the documentation of this file.
00001 // Box Delta implementation -*- C++ -*-
00002 
00003 // Copyright (C) 2001-2003 Hermann Schichl
00004 //
00005 // This file is part of the COCONUT API.  This library
00006 // is free software; you can redistribute it and/or modify it under the
00007 // terms of the Library GNU General Public License as published by the
00008 // Free Software Foundation; either version 2, or (at your option)
00009 // any later version.
00010 
00011 // This library is distributed in the hope that it will be useful,
00012 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00013 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014 // Library GNU General Public License for more details.
00015 
00016 // As a special exception, you may use this file as part of a free software
00017 // library without restriction.  Specifically, if other files instantiate
00018 // templates or use macros or inline functions from this file, or you compile
00019 // this file and link it with other files to produce an executable, this
00020 // file does not by itself cause the resulting executable to be covered by
00021 // the Library GNU General Public License.  This exception does not however
00022 // invalidate any other reasons why the executable file might be covered by
00023 // the Library GNU General Public License.
00024 
00027 #ifndef _BOXES_DELTA_H_
00028 #define _BOXES_DELTA_H_
00029 
00030 #include <api_delta.h>
00031 #include <table_delta.h>
00032 
00033 class boxes_delta : public table_delta
00034 {
00035 private:
00036   typedef table_delta _Base;
00037 
00038 public:
00039   boxes_delta(bool _add=true) : _Base(_add ? "add box" : "exclusion box") {}
00040 
00041   boxes_delta(const dbt_row& _b, bool _add=true) :
00042          _Base(std::string(_add ? "add box" : "exclusion box"),
00043                std::string("box"), _b) {}
00044 
00045   boxes_delta(const std::vector<dbt_row>& _b, bool _add=true) :
00046          _Base(std::string(_add ? "add box" : "exclusion box"),
00047                std::string("box"), _b) {}
00048 
00049   boxes_delta(const boxes_delta& __d) : _Base(__d) {}
00050 
00051   boxes_delta* new_copy() const { return new boxes_delta(*this); }
00052 
00053   void destroy_copy(boxes_delta* __d) { delete __d; }
00054 
00055   void create_table(work_node& _x, vdbl::standard_table *&ptb,
00056                     const std::string& __t) const;
00057 
00058   bool apply(work_node& _x, undelta_base*& _u) const;
00059 };
00060 
00061 #endif /* _BOXES_DELTA_H_ */

Generated on Tue Nov 4 01:57:56 2003 for COCONUT API by doxygen1.2.18