![]() |
Black Box
|
Public Member Functions | |
delegate void | UpdateProgressSub (int CurrentLine) |
BBSD2DB () | |
void | SplitXML (string FilePath, int LineCount, int MaxXlmFiles, UpdateProgressSub Status, ref bool IsAbort) |
Stream the encrypted file and decrypt it. If file too large, file is split More... | |
void | SplitIt () |
Calls the splitXml method and notify the user of progress success or failure More... | |
void | UpdateProgress (int CurrentLine) |
Display the total lines written after split More... | |
Protected Member Functions | |
override void | Dispose (bool disposing) |
Clean up any resources being used. More... | |
Private Member Functions | |
void | insertData () |
Insert data into database More... | |
void | BBPSD2DB_Load (object sender, EventArgs e) |
void | browseFileBtn_Click (object sender, EventArgs e) |
Executes the open file command More... | |
void | cancelBtn_Click (object sender, EventArgs e) |
Cancel the process More... | |
void | startBtn_Click (object sender, EventArgs e) |
Start the process More... | |
void | InitializeComponent () |
Required method for Designer support - do not modify the contents of this method with the code editor. More... | |
Static Private Member Functions | |
static void | CreatePresenseSensorTable () |
Setting up data table for presence sensor More... | |
static void | CreateThermostatTable () |
Setting up data table for thermostat More... | |
static void | BB_Database (string BBData) |
parse sensor's data More... | |
static string | CalculateFileSize (long TotalSize) |
Calculating File size More... | |
Private Attributes | |
bool | abortXmlProcess |
int | FileIndex = 0 |
string | OutputFolder |
int | linesWritten = 0 |
long | Results |
int | blockSize = 0 |
Variables for bulk insert More... | |
System.ComponentModel.IContainer | components = null |
Required designer variable. More... | |
System.Windows.Forms.TextBox | xmlFile |
System.Windows.Forms.Button | browseFileBtn |
System.Windows.Forms.Label | fName |
System.Windows.Forms.Label | fSize |
System.Windows.Forms.Button | cancelBtn |
System.Windows.Forms.Button | startBtn |
System.Windows.Forms.ProgressBar | xmlProgress |
System.Windows.Forms.GroupBox | groupBox1 |
System.Windows.Forms.GroupBox | groupBox2 |
System.Windows.Forms.GroupBox | groupBox3 |
System.Windows.Forms.PictureBox | DBConnectionStatus |
System.Windows.Forms.GroupBox | groupBox4 |
System.Windows.Forms.PictureBox | DBTransferStatus |
System.Windows.Forms.PictureBox | pIcon |
System.Windows.Forms.GroupBox | groupBox5 |
System.Windows.Forms.GroupBox | groupBox6 |
System.Windows.Forms.Label | pPerc |
Static Private Attributes | |
static string | line |
static string [] | BBPSensorParsedData |
static DataTable | BBPresenseSensorsData = new DataTable("dbo.BBPresenseSensorsData") |
static DataTable | BBThermostatData = new DataTable("dbo.BBThermostatData") |
static SqlConnection | cn |
static string | tableType |
static int | linePerFile = 100 |
static int | maxFileCount = 100 |
static string | DB_Connection = ConfigurationManager.ConnectionStrings["BB_db_CONNECTION"].ConnectionString |
Initializing Connection parameters More... | |
Definition at line 20 of file BBSD2DB.cs.
BBPSensorData2DataBase.BBSD2DB.BBSD2DB | ( | ) |
Definition at line 56 of file BBSD2DB.cs.
|
staticprivate |
parse sensor's data
BBData |
Getting Sensor Data parsed from string
Getting Sensor Data parsed from string
Definition at line 108 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.SplitXML().
|
private |
sender | |
e |
Definition at line 307 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.InitializeComponent().
|
private |
Executes the open file command
sender | |
e |
Getting file info
Definition at line 320 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.InitializeComponent().
|
staticprivate |
Calculating File size
TotalSize |
Definition at line 273 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.browseFileBtn_Click().
|
private |
Cancel the process
sender | |
e |
Definition at line 467 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.InitializeComponent().
|
staticprivate |
Setting up data table for presence sensor
Definition at line 68 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.BBPSD2DB_Load().
|
staticprivate |
Setting up data table for thermostat
Definition at line 82 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.BBPSD2DB_Load().
|
protected |
Clean up any resources being used.
disposing | true if managed resources should be disposed; otherwise, false. |
Definition at line 14 of file BBSD2DB.Designer.cs.
|
private |
Required method for Designer support - do not modify the contents of this method with the code editor.
Definition at line 29 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.BBSD2DB().
|
private |
Insert data into database
Definition at line 166 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.SplitXML().
void BBPSensorData2DataBase.BBSD2DB.SplitIt | ( | ) |
Calls the splitXml method and notify the user of progress success or failure
Definition at line 423 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.startBtn_Click().
void BBPSensorData2DataBase.BBSD2DB.SplitXML | ( | string | FilePath, |
int | LineCount, | ||
int | MaxXlmFiles, | ||
UpdateProgressSub | Status, | ||
ref bool | IsAbort | ||
) |
Stream the encrypted file and decrypt it. If file too large, file is split
FilePath | |
LineCount | |
MaxXlmFiles | |
Status | |
IsAbort |
Definition at line 366 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.SplitIt().
|
private |
Start the process
sender | |
e |
Definition at line 477 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.InitializeComponent().
void BBPSensorData2DataBase.BBSD2DB.UpdateProgress | ( | int | CurrentLine | ) |
Display the total lines written after split
CurrentLine |
Definition at line 457 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.SplitIt().
delegate void BBPSensorData2DataBase.BBSD2DB.UpdateProgressSub | ( | int | CurrentLine | ) |
|
private |
Definition at line 33 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.cancelBtn_Click(), and BBPSensorData2DataBase.BBSD2DB.SplitIt().
|
staticprivate |
Definition at line 26 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.BB_Database(), BBPSensorData2DataBase.BBSD2DB.CreatePresenseSensorTable(), and BBPSensorData2DataBase.BBSD2DB.insertData().
|
staticprivate |
Definition at line 25 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.BB_Database().
|
staticprivate |
Definition at line 27 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.BB_Database(), BBPSensorData2DataBase.BBSD2DB.CreateThermostatTable(), and BBPSensorData2DataBase.BBSD2DB.insertData().
|
private |
Variables for bulk insert
Definition at line 50 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.SplitXML().
|
private |
Definition at line 267 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.InitializeComponent().
|
private |
Definition at line 270 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.InitializeComponent(), and BBPSensorData2DataBase.BBSD2DB.SplitIt().
|
staticprivate |
Definition at line 28 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.insertData().
|
private |
Required designer variable.
Definition at line 8 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.Dispose().
|
staticprivate |
Initializing Connection parameters
Definition at line 43 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.insertData().
|
private |
Definition at line 276 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.browseFileBtn_Click(), BBPSensorData2DataBase.BBSD2DB.InitializeComponent(), and BBPSensorData2DataBase.BBSD2DB.insertData().
|
private |
Definition at line 278 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.browseFileBtn_Click(), BBPSensorData2DataBase.BBSD2DB.InitializeComponent(), and BBPSensorData2DataBase.BBSD2DB.insertData().
|
private |
Definition at line 34 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.SplitXML().
|
private |
Definition at line 268 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.browseFileBtn_Click(), and BBPSensorData2DataBase.BBSD2DB.InitializeComponent().
|
private |
Definition at line 269 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.browseFileBtn_Click(), and BBPSensorData2DataBase.BBSD2DB.InitializeComponent().
|
private |
Definition at line 273 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.InitializeComponent().
|
private |
Definition at line 274 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.InitializeComponent().
|
private |
Definition at line 275 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.InitializeComponent().
|
private |
Definition at line 277 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.InitializeComponent().
|
private |
Definition at line 280 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.InitializeComponent().
|
private |
Definition at line 281 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.InitializeComponent().
|
staticprivate |
Definition at line 24 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.SplitXML().
|
staticprivate |
Definition at line 37 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.CalculateFileSize(), and BBPSensorData2DataBase.BBSD2DB.SplitIt().
|
private |
Definition at line 36 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.UpdateProgress().
|
staticprivate |
Definition at line 38 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.SplitIt().
|
private |
Definition at line 35 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.SplitXML().
|
private |
Definition at line 279 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.browseFileBtn_Click(), BBPSensorData2DataBase.BBSD2DB.InitializeComponent(), BBPSensorData2DataBase.BBSD2DB.insertData(), and BBPSensorData2DataBase.BBSD2DB.SplitIt().
|
private |
Definition at line 282 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.browseFileBtn_Click(), BBPSensorData2DataBase.BBSD2DB.InitializeComponent(), and BBPSensorData2DataBase.BBSD2DB.SplitXML().
|
private |
Definition at line 45 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.browseFileBtn_Click().
|
private |
Definition at line 271 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.InitializeComponent(), and BBPSensorData2DataBase.BBSD2DB.SplitIt().
|
staticprivate |
Definition at line 29 of file BBSD2DB.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.BB_Database(), BBPSensorData2DataBase.BBSD2DB.browseFileBtn_Click(), and BBPSensorData2DataBase.BBSD2DB.insertData().
|
private |
Definition at line 266 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.browseFileBtn_Click(), BBPSensorData2DataBase.BBSD2DB.InitializeComponent(), and BBPSensorData2DataBase.BBSD2DB.SplitIt().
|
private |
Definition at line 272 of file BBSD2DB.Designer.cs.
Referenced by BBPSensorData2DataBase.BBSD2DB.browseFileBtn_Click(), BBPSensorData2DataBase.BBSD2DB.InitializeComponent(), and BBPSensorData2DataBase.BBSD2DB.SplitXML().