1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
|
#[derive(Debug)]
pub struct Phar {
path: String,
}
impl Phar {
pub const ZIP: i64 = 1;
pub const TAR: i64 = 2;
pub const GZ: i64 = 4096;
pub const BZ2: i64 = 8192;
pub fn new(_a: String) -> Self {
todo!()
}
pub fn extract_to(&self, _a: &str, _b: Option<()>, _c: bool) {
todo!()
}
pub fn running(_return_full: bool) -> String {
todo!()
}
}
impl Phar {
pub const SHA512: i64 = 16;
pub fn new_phar(_filename: String, _flags: i64, _alias: &str) -> Self {
todo!()
}
pub fn set_signature_algorithm(&mut self, _algo: i64) {
todo!()
}
pub fn start_buffering(&mut self) {
todo!()
}
pub fn stop_buffering(&mut self) {
todo!()
}
pub fn add_from_string(&mut self, _path: &str, _content: &str) {
todo!()
}
pub fn set_stub(&mut self, _stub: &str) {
todo!()
}
}
#[derive(Debug)]
pub struct PharException {
pub message: String,
pub code: i64,
}
impl std::fmt::Display for PharException {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
f.write_str(&self.message)
}
}
impl std::error::Error for PharException {}
#[derive(Debug)]
pub struct PharFileInfo;
impl PharFileInfo {
pub fn get_content(&self) -> String {
todo!()
}
pub fn get_basename(&self) -> String {
todo!()
}
pub fn is_dir(&self) -> bool {
todo!()
}
}
#[derive(Debug)]
pub struct PharData {
path: String,
}
impl PharData {
pub fn new(_a: String) -> Self {
todo!()
}
pub fn new_with_format(_path: String, _flags: i64, _alias: &str, _format: i64) -> Self {
todo!()
}
pub fn can_compress(_algo: i64) -> bool {
todo!()
}
pub fn valid(&self) -> bool {
todo!()
}
pub fn get(&self, _key: &str) -> Option<PharFileInfo> {
todo!()
}
pub fn iter(&self) -> impl Iterator<Item = PharFileInfo> {
todo!();
std::iter::empty()
}
pub fn extract_to(&self, _a: &str, _b: Option<()>, _c: bool) {
todo!()
}
pub fn add_empty_dir(&self, _a: &str) {
todo!()
}
pub fn build_from_iterator(
&self,
_iter: &mut dyn Iterator<Item = std::path::PathBuf>,
_base: &str,
) {
todo!()
}
pub fn compress(&self, _algo: i64) {
todo!()
}
}
|