OpenGrok
Home
Sort by relevance
Sort by last modified time
Full Search
Definition
Symbol
File Path
History
|
|
Help
Searched
refs:ByteSource
(Results
1 - 25
of
48
) sorted by null
1
2
/external/guava/guava-tests/test/com/google/common/io/
MultiInputStreamTest.java
49
final
ByteSource
source = newByteSource(0, 50);
51
ByteSource
checker = new
ByteSource
() {
65
byte[] result =
ByteSource
.concat(checker, checker, checker).read();
70
List<
ByteSource
> sources = Lists.newArrayList();
76
ByteSource
joined =
ByteSource
.concat(sources);
81
ByteSource
source = newByteSource(0, 10);
82
ByteSource
joined =
ByteSource
.concat(source, source)
[
all
...]
ByteSourceTest.java
45
* Tests for the default implementations of {@code
ByteSource
} methods.
53
suite.addTest(ByteSourceTester.tests("
ByteSource
.wrap[byte[]]",
55
suite.addTest(ByteSourceTester.tests("
ByteSource
.empty[]",
167
ByteSource
byteSource
= new TestByteSource("hamburger\n".getBytes(Charsets.US_ASCII));
170
assertEquals("cfa0c5002275c90508338a5cdb2a9781",
byteSource
.hash(Hashing.md5()).toString());
177
ByteSource
equalSource = new TestByteSource(bytes);
181
ByteSource
fewerBytes = new TestByteSource(newPreFilledByteArray(bytes.length / 2));
186
ByteSource
oneByteOff = new TestByteSource(copy);
222
* @param offset the first argument to {@link
ByteSource
#slice
[
all
...]
SourceSinkFactory.java
79
* Factory for {@link
ByteSource
} instances.
81
public interface ByteSourceFactory extends SourceFactory<
ByteSource
, byte[]> {
FileBackedOutputStreamTest.java
81
ByteSource
source = out.asByteSource();
88
assertTrue(
ByteSource
.wrap(data).slice(0, chunk1).contentEquals(source));
130
ByteSource
source = out.asByteSource();
151
ByteSource
source = out.asByteSource();
TestByteSource.java
33
public final class TestByteSource extends
ByteSource
implements TestStreamSupplier {
SourceSinkFactories.java
159
public
ByteSource
createSource(byte[] bytes) throws IOException {
196
public
ByteSource
createSource(byte[] bytes) throws IOException {
197
return
ByteSource
.wrap(bytes);
230
public
ByteSource
createSource(byte[] bytes) throws IOException {
231
return
ByteSource
.empty();
271
public
ByteSource
createSource(byte[] bytes) throws IOException {
408
public
ByteSource
createSource(byte[] bytes) throws IOException {
ByteSourceTester.java
40
* A generator of {@code TestSuite} instances for testing {@code
ByteSource
} implementations.
41
* Generates tests of a all methods on a {@code
ByteSource
} given various inputs the source is
47
public class ByteSourceTester extends SourceSinkTester<
ByteSource
, byte[], ByteSourceFactory> {
82
// test a random slice() of the
ByteSource
96
private
ByteSource
source;
160
assertTrue(source.contentEquals(new
ByteSource
() {
/prebuilts/tools/darwin-x86_64/protoc/include/google/protobuf/stubs/
bytestream.h
31
// This file declares the ByteSink and
ByteSource
abstract interfaces. These
32
// interfaces represent objects that consume (ByteSink) or produce (
ByteSource
)
46
//
ByteSource
:
99
//
ByteSource
* source = ...
106
class LIBPROTOBUF_EXPORT
ByteSource
{
108
ByteSource
() {}
109
virtual ~
ByteSource
() {}
113
// increase. Available() returning 0 indicates that the
ByteSource
is
117
// indicative of the fixed-size nature of a
ByteSource
.
135
// Writes the next n bytes in this
ByteSource
to the given ByteSink, an
[
all
...]
/external/guava/guava/src/com/google/common/io/
ByteSource.java
43
* {@code
ByteSource
} is not an open, stateful stream for input that can be read and closed.
46
* <p>{@code
ByteSource
} provides two kinds of methods:
59
public abstract class
ByteSource
{
66
protected
ByteSource
() {}
111
public
ByteSource
slice(long offset, long length) {
308
public boolean contentEquals(
ByteSource
other) throws IOException {
335
* Concatenates multiple {@link
ByteSource
} instances into a single source. Streams returned from
342
* @return a {@code
ByteSource
} containing the concatenated data
345
public static
ByteSource
concat(Iterable<? extends
ByteSource
> sources)
[
all
...]
FileBackedOutputStream.java
45
private final
ByteSource
source;
69
* not reset the data when the {@link
ByteSource
} returned by
81
* optionally resets the data when the {@link
ByteSource
} returned
87
* be called when the {@link
ByteSource
} returned by {@link
97
source = new
ByteSource
() {
112
source = new
ByteSource
() {
122
* Returns a readable {@link
ByteSource
} view of the data that has been
127
public
ByteSource
asByteSource() {
MultiInputStream.java
36
private Iterator<? extends
ByteSource
> it;
45
Iterator<? extends
ByteSource
> it) throws IOException {
Resources.java
51
* Returns a {@link
ByteSource
} that reads from the given URL.
55
public static
ByteSource
asByteSource(URL url) {
62
private static final class UrlByteSource extends
ByteSource
{
Files.java
107
* Returns a new {@link
ByteSource
} for reading bytes from the given file.
111
public static
ByteSource
asByteSource(File file) {
115
private static final class FileByteSource extends
ByteSource
{
BaseEncoding.java
267
* Returns a {@code
ByteSource
} that reads base-encoded bytes from the specified
270
@GwtIncompatible("
ByteSource
,CharSource")
271
public final
ByteSource
decodingSource(final CharSource encodedSource) {
273
return new
ByteSource
() {
/external/caliper/caliper/src/main/java/com/google/caliper/config/
CaliperConfigLoader.java
25
import com.google.common.io.
ByteSource
;
67
ByteSource
supplier = Util.resourceSupplier(CaliperConfig.class, "default-config.properties");
89
private static void tryCopyIfNeeded(
ByteSource
supplier, File rcFile) {
/external/caliper/caliper/src/main/java/com/google/caliper/util/
Util.java
23
import com.google.common.io.
ByteSource
;
69
public static ImmutableMap<String, String> loadProperties(
ByteSource
is) throws IOException {
81
public static
ByteSource
resourceSupplier(final Class<?> c, final String name) {
/external/guava/guava-testlib/src/com/google/common/testing/
ArbitraryInstances.java
72
import com.google.common.io.
ByteSource
;
232
.put(
ByteSource
.class,
ByteSource
.empty())
/external/guava/guava-testlib/test/com/google/common/testing/
ArbitraryInstancesTest.java
57
import com.google.common.io.
ByteSource
;
335
assertEquals(
ByteSource
.empty(), ArbitraryInstances.get(
ByteSource
.class));
/external/guice/lib/
guava-16.0.1.jar
/prebuilts/devtools/tools/lib/
guava-17.0.jar
/prebuilts/misc/common/guava/
guava-15.0.jar
/prebuilts/misc/common/tradefed/
tradefed-prebuilt.jar
/prebuilts/tools/common/m2/repository/com/google/guava/guava/15.0/
guava-15.0.jar
/prebuilts/tools/common/m2/repository/com/google/guava/guava/17.0/
guava-17.0.jar
/prebuilts/tools/common/offline-m2/com/google/guava/guava/17.0/
guava-17.0.jar
Completed in 284 milliseconds
1
2