sbuild-chroot-file.h

Go to the documentation of this file.
00001 /* Copyright © 2005-2008  Roger Leigh <rleigh@debian.org>
00002  *
00003  * schroot is free software: you can redistribute it and/or modify it
00004  * under the terms of the GNU General Public License as published by
00005  * the Free Software Foundation, either version 3 of the License, or
00006  * (at your option) any later version.
00007  *
00008  * schroot is distributed in the hope that it will be useful, but
00009  * WITHOUT ANY WARRANTY; without even the implied warranty of
00010  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00011  * General Public License for more details.
00012  *
00013  * You should have received a copy of the GNU General Public License
00014  * along with this program.  If not, see
00015  * <http://www.gnu.org/licenses/>.
00016  *
00017  *********************************************************************/
00018 
00019 #ifndef SBUILD_CHROOT_FILE_H
00020 #define SBUILD_CHROOT_FILE_H
00021 
00022 #include <sbuild/sbuild-chroot.h>
00023 
00024 namespace sbuild
00025 {
00026 
00032   class chroot_file : public chroot
00033   {
00034   protected:
00036     chroot_file ();
00037 
00039     chroot_file (const chroot_file& rhs);
00040 
00041     friend class chroot;
00042 
00043   public:
00045     virtual ~chroot_file ();
00046 
00047     virtual chroot::ptr
00048     clone () const;
00049 
00050     virtual chroot::ptr
00051     clone_session (std::string const& session_id,
00052                    std::string const& user,
00053                    bool               root) const;
00054 
00055     virtual chroot::ptr
00056     clone_source () const;
00057 
00063     std::string const&
00064     get_file () const;
00065 
00071     void
00072     set_file (std::string const& file);
00073 
00080     bool
00081     get_file_repack () const;
00082 
00090     void
00091     set_file_repack (bool repack);
00092 
00093     virtual std::string const&
00094     get_chroot_type () const;
00095 
00096     virtual void
00097     setup_env (chroot const& chroot,
00098                environment& env) const;
00099 
00100     std::string
00101     get_path () const;
00102 
00103     virtual session_flags
00104     get_session_flags (chroot const& chroot) const;
00105 
00106   protected:
00107     virtual void
00108     setup_lock (chroot::setup_type type,
00109                 bool               lock,
00110                 int                status);
00111 
00112     virtual void
00113     get_details (chroot const&  chroot,
00114                  format_detail& detail) const;
00115 
00116     virtual void
00117     get_keyfile (chroot const& chroot,
00118                  keyfile&      keyfile) const;
00119 
00120     virtual void
00121     set_keyfile (chroot&        chroot,
00122                  keyfile const& keyfile,
00123                  string_list&   used_keys);
00124 
00125   private:
00127     std::string file;
00129     bool repack;
00130   };
00131 
00132 }
00133 
00134 #endif /* SBUILD_CHROOT_FILE_H */
00135 
00136 /*
00137  * Local Variables:
00138  * mode:C++
00139  * End:
00140  */
Generated on Sat Apr 3 02:43:46 2010 for sbuild by  doxygen 1.6.3