MSSQLDataFile.h
Go to the documentation of this file.
1 #pragma once
2 
3 namespace AppSecInc
4 {
5  namespace Databases
6  {
7  namespace MSSQL
8  {
11  {
12  private:
13  std::wstring _database;
14  std::wstring _schema;
15  std::wstring _table;
16  std::wstring _filename;
17  std::list<std::wstring> _parameters;
18  public:
20  const std::wstring& GetDatabase() const { return _database; }
21  void SetDatabase(const std::wstring& value) { _database = value; }
23  const std::wstring& GetSchema() const { return _schema; }
24  void SetSchema(const std::wstring& value) { _schema = value; }
26  const std::wstring& GetTable() const { return _table; }
27  void SetTable(const std::wstring& value) { _table = value; }
29  const std::wstring& GetFilename() const { return _filename; }
30  void SetFilename(const std::wstring& value) { _filename = value; }
32  const std::list<std::wstring>& GetParameters() const { return _parameters; }
34  void AddParameter(const std::wstring& value) { _parameters.push_back(value); }
35  void AddParameter(const std::wstring& name, const std::wstring& value);
36  public:
37  std::wstring GetInsertQuery() const;
38  friend std::wostream& operator<<(std::wostream&, const MSSQLDataFile&);
42  MSSQLDataFile();
46  MSXML2::IXMLDOMNodePtr Save(AppSecInc::Xml::XmlDocument& xmldoc, MSXML2::IXMLDOMNodePtr parent) const;
48  void Load(AppSecInc::Xml::XmlDocument& xmldoc, MSXML2::IXMLDOMNodePtr root);
49  };
50  }
51  }
52 }
const std::wstring & GetTable() const
the operating-system file name for the database file
Definition: MSSQLDataFile.h:26
const std::wstring & GetDatabase() const
get the database name
Definition: MSSQLDataFile.h:20
std::wstring GetInsertQuery() const
Definition: MSSQLDataFile.cpp:37
MSSQLDataFile()
constructors/destructors
Definition: MSSQLDataFile.cpp:26
const std::wstring & GetSchema() const
the schema name
Definition: MSSQLDataFile.h:23
void AddParameter(const std::wstring &value)
add a data file option
Definition: MSSQLDataFile.h:34
friend std::wostream & operator<<(std::wostream &, const MSSQLDataFile &)
void SetFilename(const std::wstring &value)
Definition: MSSQLDataFile.h:30
void SetSchema(const std::wstring &value)
Definition: MSSQLDataFile.h:24
const std::wstring & GetFilename() const
the name of the data file
Definition: MSSQLDataFile.h:29
const std::list< std::wstring > & GetParameters() const
get the parameters
Definition: MSSQLDataFile.h:32
An MSXML document.
Definition: XmlDocument.h:8
void SetTable(const std::wstring &value)
Definition: MSSQLDataFile.h:27
~MSSQLDataFile()
Definition: MSSQLDataFile.cpp:7
A Microsoft SQL Server database file specification.
Definition: MSSQLDataFile.h:10
MSSQLDataFile & operator=(const MSSQLDataFile &)
copy constructor and operator=
Definition: MSSQLDataFile.cpp:11
MSXML2::IXMLDOMNodePtr Save(AppSecInc::Xml::XmlDocument &xmldoc, MSXML2::IXMLDOMNodePtr parent) const
serialize the data file spec to xml
Definition: MSSQLDataFile.cpp:59
void SetDatabase(const std::wstring &value)
Definition: MSSQLDataFile.h:21
void Load(AppSecInc::Xml::XmlDocument &xmldoc, MSXML2::IXMLDOMNodePtr root)
deserialize the data file spec from xml
Definition: MSSQLDataFile.cpp:74


© Application Security Inc. - All Rights Reserved http://msiext.codeplex.com