blob: ca0ea9f33cabf94ff7e39fd89957edadd9d0ecdb [file] [log] [blame]
Dees_Troy812660f2012-09-20 09:55:17 -04001/* OpenRecoveryScript class for TWRP
2 *
3 * This program is free software; you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License version 2 and
5 * only version 2 as published by the Free Software Foundation.
6 *
7 * This program is distributed in the hope that it will be useful,
8 * but WITHOUT ANY WARRANTY; without even the implied warranty of
9 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10 * GNU General Public License for more details.
11 *
12 * You should have received a copy of the GNU General Public License
13 * along with this program; if not, write to the Free Software
14 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
15 * 02110-1301, USA.
16 *
17 * The code was written from scratch by Dees_Troy dees_troy at
18 * yahoo
19 *
20 * Copyright (c) 2012
21 */
22
23#ifndef _OPENRECOVERYSCRIPT_HPP
24#define _OPENRECOVERYSCRIPT_HPP
25
26#include <string>
27
28using namespace std;
29
30// Partition class
31class OpenRecoveryScript
32{
33public:
34 static int check_for_script_file(); // Checks to see if the ORS file is present in /cache
35 static int run_script_file(); // Executes the commands in the ORS file
Dees_Troy83a3b122012-10-01 14:16:43 -040036 static int Install_Command(string Zip); // Installs a zip
Dees_Troy812660f2012-09-20 09:55:17 -040037 static string Locate_Zip_File(string Path, string File); // Attempts to locate the zip file in storage
Dees_Troy83a3b122012-10-01 14:16:43 -040038 static int Backup_Command(string Options); // Runs a backup
Dees_Troy812660f2012-09-20 09:55:17 -040039
40};
41
42#endif // _OPENRECOVERYSCRIPT_HPP