• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

sirn-se / websocket-php / 8346487915

19 Mar 2024 04:15PM UTC coverage: 22.584% (-77.4%) from 100.0%
8346487915

push

github

sirn-se
Temp test verification

2 of 2 new or added lines in 1 file covered. (100.0%)

742 existing lines in 32 files now uncovered.

222 of 983 relevant lines covered (22.58%)

0.23 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/Http/ServerRequest.php
1
<?php
2

3
/**
4
 * Copyright (C) 2014-2024 Textalk and contributors.
5
 * This file is part of Websocket PHP and is free software under the ISC License.
6
 */
7

8
namespace WebSocket\Http;
9

10
use BadMethodCallException;
11
use Psr\Http\Message\{
12
    ServerRequestInterface,
13
    UriInterface
14
};
15

16
/**
17
 * WebSocket\Http\ServerRequest class.
18
 * Only used for handshake procedure.
19
 */
20
class ServerRequest extends Request implements ServerRequestInterface
21
{
22
    /**
23
     * Retrieve server parameters.
24
     * @return array
25
     */
26
    public function getServerParams(): array
27
    {
UNCOV
28
        throw new BadMethodCallException("Not implemented.");
×
29
    }
30

31
    /**
32
     * Retrieves cookies sent by the client to the server.
33
     * @return array
34
     */
35
    public function getCookieParams(): array
36
    {
UNCOV
37
        throw new BadMethodCallException("Not implemented.");
×
38
    }
39

40
    /**
41
     * Return an instance with the specified cookies.
42
     * @param array $cookies Array of key/value pairs representing cookies.
43
     * @return static
44
     */
45
    public function withCookieParams(array $cookies): self
46
    {
UNCOV
47
        throw new BadMethodCallException("Not implemented.");
×
48
    }
49

50
    /**
51
     * Retrieves the deserialized query string arguments, if any.
52
     * @return array
53
     */
54
    public function getQueryParams(): array
55
    {
UNCOV
56
        parse_str($this->getUri()->getQuery(), $result);
×
UNCOV
57
        return $result;
×
58
    }
59

60
    /**
61
     * Return an instance with the specified query string arguments.
62
     * @param array $query Array of query string arguments
63
     * @return static
64
     */
65
    public function withQueryParams(array $query): self
66
    {
UNCOV
67
        throw new BadMethodCallException("Not implemented.");
×
68
    }
69

70
    /**
71
     * Retrieve normalized file upload data.
72
     * @return array An array tree of UploadedFileInterface instances.
73
     */
74
    public function getUploadedFiles(): array
75
    {
UNCOV
76
        throw new BadMethodCallException("Not implemented.");
×
77
    }
78

79
    /**
80
     * Create a new instance with the specified uploaded files.
81
     * @param array $uploadedFiles An array tree of UploadedFileInterface instances.
82
     * @return static
83
     * @throws \InvalidArgumentException if an invalid structure is provided.
84
     */
85
    public function withUploadedFiles(array $uploadedFiles): self
86
    {
UNCOV
87
        throw new BadMethodCallException("Not implemented.");
×
88
    }
89

90
    /**
91
     * Retrieve any parameters provided in the request body.
92
     * @return null|array|object The deserialized body parameters, if any.
93
     */
94
    public function getParsedBody()
95
    {
UNCOV
96
        throw new BadMethodCallException("Not implemented.");
×
97
    }
98

99
    /**
100
     * Return an instance with the specified body parameters.
101
     * @param null|array|object $data The deserialized body data.
102
     * @return static
103
     * @throws \InvalidArgumentException if an unsupported argument type is provided.
104
     */
105
    public function withParsedBody($data): self
106
    {
UNCOV
107
        throw new BadMethodCallException("Not implemented.");
×
108
    }
109

110
    /**
111
     * Retrieve attributes derived from the request.
112
     * @return mixed[] Attributes derived from the request.
113
     */
114
    public function getAttributes(): array
115
    {
UNCOV
116
        throw new BadMethodCallException("Not implemented.");
×
117
    }
118

119
    /**
120
     * Retrieve a single derived request attribute.
121
     * @param string $name The attribute name.
122
     * @param mixed $default Default value to return if the attribute does not exist.
123
     * @return mixed
124
     */
125
    public function getAttribute(string $name, $default = null)
126
    {
UNCOV
127
        throw new BadMethodCallException("Not implemented.");
×
128
    }
129

130
    /**
131
     * Return an instance with the specified derived request attribute.
132
     * @param string $name The attribute name.
133
     * @param mixed $value The value of the attribute.
134
     * @return static
135
     */
136
    public function withAttribute(string $name, $value): self
137
    {
UNCOV
138
        throw new BadMethodCallException("Not implemented.");
×
139
    }
140

141
    /**
142
     * Return an instance that removes the specified derived request attribute.
143
     * @param string $name The attribute name.
144
     * @return static
145
     */
146
    public function withoutAttribute(string $name): self
147
    {
UNCOV
148
        throw new BadMethodCallException("Not implemented.");
×
149
    }
150

151
    public function __toString(): string
152
    {
UNCOV
153
        return $this->stringable('%s %s', $this->getMethod(), $this->getRequestTarget());
×
154
    }
155
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc