Searched refs:os (Results 1 - 25 of 97) sorted by relevance

1234

/libcore/luni/src/main/java/libcore/io/
H A DLibcore.java22 public static Os os = new BlockGuardOs(new Posix()); field in class:Libcore
H A DForwardingOs.java47 protected final Os os; field in class:ForwardingOs
49 public ForwardingOs(Os os) { argument
50 this.os = os;
53 public FileDescriptor accept(FileDescriptor fd, SocketAddress peerAddress) throws ErrnoException, SocketException { return os.accept(fd, peerAddress); }
54 public boolean access(String path, int mode) throws ErrnoException { return os.access(path, mode); }
55 public InetAddress[] android_getaddrinfo(String node, StructAddrinfo hints, int netId) throws GaiException { return os.android_getaddrinfo(node, hints, netId); }
56 public void bind(FileDescriptor fd, InetAddress address, int port) throws ErrnoException, SocketException { os.bind(fd, address, port); }
57 public void bind(FileDescriptor fd, SocketAddress address) throws ErrnoException, SocketException { os.bind(fd, address); }
58 public void chmod(String path, int mode) throws ErrnoException { os
[all...]
H A DBlockGuardOs.java41 public BlockGuardOs(Os os) { argument
42 super(os);
64 return tagSocket(os.accept(fd, peerAddress));
69 return os.access(path, mode);
74 os.chmod(path, mode);
79 os.chown(path, uid, gid);
102 os.close(fd);
106 StructLinger linger = Libcore.os.getsockoptLinger(fd, SOL_SOCKET, SO_LINGER);
112 os.connect(fd, address, port);
117 os
[all...]
H A DIoBridge.java60 Libcore.os.ioctlInt(fd, FIONREAD, available);
99 Libcore.os.bind(fd, address, port);
139 Libcore.os.connect(fd, inetAddress, port);
156 Libcore.os.connect(fd, inetAddress, port);
206 Libcore.os.close(oldFd);
218 int rc = Libcore.os.poll(pollFds, remainingTimeoutMs);
222 int connectError = Libcore.os.getsockoptInt(fd, SOL_SOCKET, SO_ERROR);
265 return Libcore.os.getsockoptInAddr(fd, IPPROTO_IP, IP_MULTICAST_IF);
268 return Libcore.os.getsockoptInt(fd, IPPROTO_IPV6, IPV6_MULTICAST_IF);
272 return booleanFromInt(Libcore.os
[all...]
H A DMemoryMappedFile.java51 FileDescriptor fd = Libcore.os.open(path, O_RDONLY, 0);
52 long size = Libcore.os.fstat(fd).st_size;
53 long address = Libcore.os.mmap(0L, size, PROT_READ, MAP_SHARED, fd, 0);
54 Libcore.os.close(fd);
68 Libcore.os.munmap(address, size);
H A DIoUtils.java43 Libcore.os.close(fd);
91 int flags = Libcore.os.fcntlVoid(fd, F_GETFL);
97 Libcore.os.fcntlInt(fd, F_SETFL, flags);
163 FileDescriptor fd = Libcore.os.open(path, O_RDONLY, 0);
164 Libcore.os.close(fd);
214 final StructStat stat = Libcore.os.fstat(fd);
234 while ((read = Libcore.os.read(fd, bytes, count, capacity - count)) != 0) {
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/io/
H A DDataOutputStreamTest.java28 private DataOutputStream os; field in class:DataOutputStreamTest
49 os.writeInt(9087589);
50 os.flush();
61 os.write(fileString.getBytes(), 0, 150);
62 os.close();
67 assertEquals("Incorrect size returned", 150, os.size());
74 os.write(fileString.getBytes(), 0, 150);
75 os.close();
88 os.write((int) 't');
89 os
[all...]
H A DFilterOutputStreamTest.java30 private OutputStream os; field in class:FilterOutputStreamTest
45 os = new FilterOutputStream(bos);
46 os.write('t');
54 os = new FilterOutputStream(bos);
55 os.write(fileString.getBytes(), 0, 500);
56 os.flush();
58 os.close();
66 os = new FilterOutputStream(bos);
67 os.write(fileString.getBytes(), 0, 500);
68 os
[all...]
H A DPrintStreamTest.java54 public MockPrintStream(OutputStream os) { argument
55 super(os);
73 MockPrintStream os = new MockPrintStream(testFilePath);
74 assertNotNull(os);
75 os.close();
82 MockPrintStream os = new MockPrintStream(testFilePath, "utf-8");
83 assertNotNull(os);
84 os.close();
100 PrintStream os = new PrintStream(bos);
101 os
[all...]
H A DDataInputStreamTest.java29 private DataOutputStream os; field in class:DataInputStreamTest
44 os.writeChar('t');
45 os.close();
56 os.write(fileString.getBytes());
57 os.close();
69 os.write(fileString.getBytes());
70 os.close();
82 os.writeBoolean(true);
83 os.close();
92 os
[all...]
H A DObjectOutputStream2Test.java49 ObjectOutputStream os = new ObjectOutputStream(bos);
50 os.writeObject(MyEnum.TWO);
51 os.close();
/libcore/luni/src/test/java/libcore/java/io/
H A DOldBufferedOutputStreamTest.java28 private java.io.OutputStream os; field in class:OldBufferedOutputStreamTest
41 os = new java.io.BufferedOutputStream(baos);
42 os.write(fileString.getBytes(), 0, 500);
53 os = new java.io.BufferedOutputStream(baos, -1);
59 os = new java.io.BufferedOutputStream(baos, 1024);
60 os.write(fileString.getBytes(), 0, 500);
68 os = new java.io.BufferedOutputStream(baos, 600);
69 os.write(fileString.getBytes(), 0, 500);
70 os.flush();
73 os
[all...]
H A DOldDataOutputStreamTest.java30 private DataOutputStream os; field in class:OldDataOutputStreamTest
49 os = new DataOutputStream(buf);
50 os.writeInt(9087589);
53 os.flush();
56 os.close();
63 os = new DataOutputStream(sos);
65 os.flush();
74 os.write(testString.getBytes(), 5, testLength - 7);
75 os.close();
92 os
[all...]
H A DOldFilterOutputStreamTest.java28 private java.io.FilterOutputStream os; field in class:OldFilterOutputStreamTest
45 os = new FilterOutputStream(bos);
46 os.write('t');
54 os = new FilterOutputStream(sos);
55 os.close();
58 os.write(42);
65 os.write(42);
71 os = new FilterOutputStream(sos);
73 os.close();
82 os
[all...]
H A DOldObjectInputOutputStreamTest.java28 private ObjectOutputStream os; field in class:OldObjectInputOutputStreamTest
37 os.writeBoolean(true);
39 os.close();
61 os.writeByte((byte) 127);
63 os.close();
85 os.writeChar('b');
87 os.close();
109 os.writeDouble(2345.76834720202);
111 os.close();
133 os
[all...]
H A DDataOutputStreamTest.java27 private DataOutputStream os = new DataOutputStream(bytes); field in class:DataOutputStreamTest
30 os.writeBoolean(true);
31 os.writeBoolean(false);
36 os.writeByte(-1);
37 os.writeByte(0);
38 os.writeByte(1);
39 os.writeByte(129);
41 os.writeByte(0x1234);
47 os.writeBytes("0\u12341");
53 os
[all...]
H A DOldDataInputOutputStreamTest.java29 private DataOutputStream os; field in class:OldDataInputOutputStreamTest
38 os.writeBoolean(true);
41 os.writeBoolean(false);
48 os.close();
70 os.writeByte((byte) 127);
73 os.writeByte((byte) 127);
80 os.close();
102 os.writeChar('b');
105 os.writeChar('k');
112 os
[all...]
H A DOldDataInputStreamTest.java30 private DataOutputStream os; field in class:OldDataInputStreamTest
44 os.writeChar('t');
45 os.close();
63 os.write(fileString.getBytes());
64 os.close();
94 os.write(fileString.getBytes());
95 os.close();
124 os.write(fileString.getBytes());
125 os.close();
153 os
[all...]
H A DOutputStreamWriterTest.java34 FlushCountingOutputStream os = new FlushCountingOutputStream();
35 OutputStreamWriter writer = new OutputStreamWriter(os, "UTF-8");
41 assertEquals(0, os.flushCount);
43 assertEquals(1, os.flushCount);
45 assertEquals(1, os.flushCount);
/libcore/luni/src/main/java/android/system/
H A DOs.java43 public static FileDescriptor accept(FileDescriptor fd, InetSocketAddress peerAddress) throws ErrnoException, SocketException { return Libcore.os.accept(fd, peerAddress); }
49 public static FileDescriptor accept(FileDescriptor fd, SocketAddress peerAddress) throws ErrnoException, SocketException { return Libcore.os.accept(fd, peerAddress); }
54 public static boolean access(String path, int mode) throws ErrnoException { return Libcore.os.access(path, mode); }
56 /** @hide */ public static InetAddress[] android_getaddrinfo(String node, StructAddrinfo hints, int netId) throws GaiException { return Libcore.os.android_getaddrinfo(node, hints, netId); }
61 public static void bind(FileDescriptor fd, InetAddress address, int port) throws ErrnoException, SocketException { Libcore.os.bind(fd, address, port); }
63 /** @hide */ public static void bind(FileDescriptor fd, SocketAddress address) throws ErrnoException, SocketException { Libcore.os.bind(fd, address); }
68 public static void chmod(String path, int mode) throws ErrnoException { Libcore.os.chmod(path, mode); }
73 public static void chown(String path, int uid, int gid) throws ErrnoException { Libcore.os.chown(path, uid, gid); }
78 public static void close(FileDescriptor fd) throws ErrnoException { Libcore.os.close(fd); }
83 public static void connect(FileDescriptor fd, InetAddress address, int port) throws ErrnoException, SocketException { Libcore.os
[all...]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/zip/
H A DInflaterOutputStreamTest.java31 private ByteArrayOutputStream os = new ByteArrayOutputStream(); field in class:InflaterOutputStreamTest
41 new InflaterOutputStream(os);
55 new InflaterOutputStream(os, new Inflater());
65 new InflaterOutputStream(os, null);
76 new InflaterOutputStream(os, new Inflater(), 20);
93 new InflaterOutputStream(os, null, -1);
107 new InflaterOutputStream(os, new Inflater(), 0);
114 new InflaterOutputStream(os, new Inflater(), -10000);
125 InflaterOutputStream ios = new InflaterOutputStream(os);
135 InflaterOutputStream ios = new InflaterOutputStream(os);
[all...]
/libcore/luni/src/test/java/libcore/io/
H A DOsTest.java50 assertFalse(S_ISSOCK(Libcore.os.fstat(fis.getFD()).st_mode));
54 assertTrue(S_ISSOCK(Libcore.os.fstat(s.getImpl().getFD$()).st_mode));
63 Libcore.os.fcntlInt(fis.getFD(), F_SETFD, FD_CLOEXEC);
64 int flags = Libcore.os.fcntlVoid(fis.getFD(), F_GETFD);
84 final FileDescriptor fd = Libcore.os.socket(AF_UNIX, SOCK_STREAM, 0);
87 Libcore.os.close(fd);
92 final FileDescriptor serverFd = Libcore.os.socket(AF_UNIX, SOCK_STREAM, 0);
93 Libcore.os.bind(serverFd, address);
94 Libcore.os.listen(serverFd, 5);
102 FileDescriptor clientFd = Libcore.os
[all...]
/libcore/ojluni/src/main/java/javax/crypto/
H A DCipherOutputStream.java85 * @param os the OutputStream object
88 public CipherOutputStream(OutputStream os, Cipher c) { argument
89 super(os);
90 output = os;
101 * @param os the OutputStream object
103 protected CipherOutputStream(OutputStream os) { argument
104 super(os);
105 output = os;
/libcore/luni/src/test/java/libcore/java/util/jar/
H A DOldJarOutputStreamTest.java34 OutputStream os = new FileOutputStream(outputJar);
35 JarOutputStream jout = new JarOutputStream(os, newman);
36 os.close();
/libcore/ojluni/src/main/java/sun/net/www/protocol/mailto/
H A DMailToURLConnection.java46 OutputStream os = null; field in class:MailToURLConnection
92 if (os != null) {
93 return os;
103 os = client.startMessage();
104 return os;

Completed in 1645 milliseconds

1234