SystemInfo   A
last analyzed

Complexity

Total Complexity 30

Size/Duplication

Total Lines 242
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 30
lcom 0
cbo 1
dl 0
loc 242
ccs 0
cts 120
cp 0
rs 10
c 0
b 0
f 0

30 Methods

Rating   Name   Duplication   Size   Complexity  
A schema() 0 4 1
A host() 0 4 1
A now() 0 4 1
A start() 0 4 1
A instanceDirectory() 0 4 1
A dataDirectory() 0 4 1
A indexDirectory() 0 4 1
A solrSpecVersion() 0 4 1
A solrImplVersion() 0 4 1
A luceneSpecVersion() 0 4 1
A luceneImplVersion() 0 4 1
A jvmVersion() 0 4 1
A jvmName() 0 4 1
A jvmProcessors() 0 4 1
A jvmMemoryFree() 0 4 1
A jvmMemoryTotal() 0 4 1
A jvmMemoryMax() 0 4 1
A jvmMemoryUsed() 0 4 1
A jmxBootClassPath() 0 4 1
A jmxClassPath() 0 4 1
A jmxCommandLineArgs() 0 4 1
A jmxStartTime() 0 4 1
A jmxUptimeMS() 0 4 1
A systemName() 0 4 1
A systemVersion() 0 4 1
A systemArch() 0 4 1
A systemLoadAverage() 0 4 1
A systemUname() 0 4 1
A systemUlimit() 0 4 1
A systemUptime() 0 4 1
1
<?php
2
3
namespace PSolr\Response;
4
5
class SystemInfo extends Response
6
{
7
    /**
8
     * @return string
9
     */
10
    public function schema()
11
    {
12
        return $this['core']['schema'];
13
    }
14
15
    /**
16
     * @return string
17
     */
18
    public function host()
19
    {
20
        return $this['core']['host'];
21
    }
22
23
    /**
24
     * @return \DateTime
25
     */
26
    public function now()
27
    {
28
        return new \DateTime($this['core']['now']);
29
    }
30
31
    /**
32
     * @return \DateTime
33
     */
34
    public function start()
35
    {
36
        return new \DateTime($this['core']['start']);
37
    }
38
39
    /**
40
     * @return string
41
     */
42
    public function instanceDirectory()
43
    {
44
        return $this['core']['directory']['instance'];
45
    }
46
47
    /**
48
     * @return string
49
     */
50
    public function dataDirectory()
51
    {
52
        return $this['core']['directory']['data'];
53
    }
54
55
    /**
56
     * @return string
57
     */
58
    public function indexDirectory()
59
    {
60
        return $this['core']['directory']['index'];
61
    }
62
63
    /**
64
     * @return string
65
     */
66
    public function solrSpecVersion()
67
    {
68
        return $this['lucene']['solr-spec-version'];
69
    }
70
71
    /**
72
     * @return string
73
     */
74
    public function solrImplVersion()
75
    {
76
        return $this['lucene']['solr-impl-version'];
77
    }
78
79
    /**
80
     * @return string
81
     */
82
    public function luceneSpecVersion()
83
    {
84
        return $this['lucene']['lucene-spec-version'];
85
    }
86
87
    /**
88
     * @return string
89
     */
90
    public function luceneImplVersion()
91
    {
92
        return $this['lucene']['lucene-impl-version'];
93
    }
94
95
    /**
96
     * @return string
97
     */
98
    public function jvmVersion()
99
    {
100
        return $this['jvm']['version'];
101
    }
102
103
    /**
104
     * @return string
105
     */
106
    public function jvmName()
107
    {
108
        return $this['jvm']['version'];
109
    }
110
111
    /**
112
     * @return int
113
     */
114
    public function jvmProcessors()
115
    {
116
        return $this['jvm']['processors'];
117
    }
118
119
    /**
120
     * @return string
121
     */
122
    public function jvmMemoryFree()
123
    {
124
        return $this['jvm']['memory']['free'];
125
    }
126
127
    /**
128
     * @return string
129
     */
130
    public function jvmMemoryTotal()
131
    {
132
        return $this['jvm']['memory']['total'];
133
    }
134
135
    /**
136
     * @return string
137
     */
138
    public function jvmMemoryMax()
139
    {
140
        return $this['jvm']['memory']['max'];
141
    }
142
143
    /**
144
     * @return string
145
     */
146
    public function jvmMemoryUsed()
147
    {
148
        return $this['jvm']['memory']['used'];
149
    }
150
151
    /**
152
     * @return string
153
     */
154
    public function jmxBootClassPath()
155
    {
156
        return $this['jvm']['jmx']['bootclasspath'];
157
    }
158
159
    /**
160
     * @return string
161
     */
162
    public function jmxClassPath()
163
    {
164
        return $this['jvm']['jmx']['classpath'];
165
    }
166
167
    /**
168
     * @return array
169
     */
170
    public function jmxCommandLineArgs()
171
    {
172
        return $this['jvm']['jmx']['commandLineArgs'];
173
    }
174
175
    /**
176
     * @return \DateTime
177
     */
178
    public function jmxStartTime()
179
    {
180
        return new \DateTime($this['jvm']['jmx']['startTime']);
181
    }
182
183
    /**
184
     * @return int
185
     */
186
    public function jmxUptimeMS()
187
    {
188
        return $this['jvm']['jmx']['upTimeMS'];
189
    }
190
191
    /**
192
     * @return string
193
     */
194
    public function systemName()
195
    {
196
        return $this['system']['name'];
197
    }
198
199
    /**
200
     * @return string
201
     */
202
    public function systemVersion()
203
    {
204
        return $this['system']['version'];
205
    }
206
207
    /**
208
     * @return string
209
     */
210
    public function systemArch()
211
    {
212
        return $this['system']['arch'];
213
    }
214
215
    /**
216
     * @return float
217
     */
218
    public function systemLoadAverage()
219
    {
220
        return $this['system']['systemLoadAverage'];
221
    }
222
223
    /**
224
     * @return string
225
     */
226
    public function systemUname()
227
    {
228
        return $this['system']['uname'];
229
    }
230
231
    /**
232
     * @return init
233
     */
234
    public function systemUlimit()
235
    {
236
        return $this['system']['ulimit'];
237
    }
238
239
    /**
240
     * @return string
241
     */
242
    public function systemUptime()
243
    {
244
        return $this['system']['uptime'];
245
    }
246
}
247