Swift_OutputByteStream
last analyzed

Size/Duplication

Total Lines 28
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
dl 0
loc 28
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
read() 0 1 ?
setReadPointer() 0 1 ?
1
<?php
2
3
/*
4
 * This file is part of SwiftMailer.
5
 * (c) 2004-2009 Chris Corbyn
6
 *
7
 * For the full copyright and license information, please view the LICENSE
8
 * file that was distributed with this source code.
9
 */
10
11
/**
12
 * An abstract means of reading data.
13
 *
14
 * Classes implementing this interface may use a subsystem which requires less
15
 * memory than working with large strings of data.
16
 *
17
 * @author Chris Corbyn
18
 */
19
interface Swift_OutputByteStream
0 ignored issues
show
Coding Style Compatibility introduced by
Each interface must be in a namespace of at least one level (a top-level vendor name)

You can fix this by adding a namespace to your class:

namespace YourVendor;

class YourClass { }

When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.

Loading history...
20
{
21
    /**
22
     * Reads $length bytes from the stream into a string and moves the pointer
23
     * through the stream by $length.
24
     *
25
     * If less bytes exist than are requested the remaining bytes are given instead.
26
     * If no bytes are remaining at all, boolean false is returned.
27
     *
28
     * @param int $length
29
     *
30
     * @throws Swift_IoException
31
     *
32
     * @return string|bool
33
     */
34
    public function read($length);
35
36
    /**
37
     * Move the internal read pointer to $byteOffset in the stream.
38
     *
39
     * @param int $byteOffset
40
     *
41
     * @throws Swift_IoException
42
     *
43
     * @return bool
44
     */
45
    public function setReadPointer($byteOffset);
46
}
47