commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mt...@apache.org
Subject svn commit: r1130478 - in /commons/sandbox/runtime/trunk/src/main: java/org/apache/commons/runtime/net/ native/os/unix/
Date Thu, 02 Jun 2011 10:40:34 GMT
Author: mturk
Date: Thu Jun  2 10:40:33 2011
New Revision: 1130478

URL: http://svn.apache.org/viewvc?rev=1130478&view=rev
Log:
Axe socket part from the local endpoint. They are not always sockets

Added:
    commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalDescriptor.java
      - copied, changed from r1130435, commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalSocketDescriptor.java
    commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalEndpoint.java
      - copied, changed from r1130435, commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalSocketEndpoint.java
Removed:
    commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalSocketDescriptor.java
    commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalSocketEndpoint.java
Modified:
    commons/sandbox/runtime/trunk/src/main/native/os/unix/usock.c

Copied: commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalDescriptor.java
(from r1130435, commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalSocketDescriptor.java)
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalDescriptor.java?p2=commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalDescriptor.java&p1=commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalSocketDescriptor.java&r1=1130435&r2=1130478&rev=1130478&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalSocketDescriptor.java
(original)
+++ commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalDescriptor.java
Thu Jun  2 10:40:33 2011
@@ -26,24 +26,24 @@ import org.apache.commons.runtime.io.Clo
 import org.apache.commons.runtime.io.Descriptor;
 
 /**
- * Package private Local Socket Descriptor.
+ * Package private Local Descriptor.
  * <p>
  * Local socket represents either unix domain socket or a windows pipe,
  * depending on the operating system.
  * </p>
  * @since Runtime 1.0
  */
-final class LocalSocketDescriptor extends Descriptor
+final class LocalDescriptor extends Descriptor
 {
 
     private static native int close0(int fd);
     private static native int sendz0(int fd);
 
-    public LocalSocketDescriptor()
+    public LocalDescriptor()
     {
     }
 
-    public LocalSocketDescriptor(int fd)
+    public LocalDescriptor(int fd)
     {
         this.fd = fd;
     }

Copied: commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalEndpoint.java
(from r1130435, commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalSocketEndpoint.java)
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalEndpoint.java?p2=commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalEndpoint.java&p1=commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalSocketEndpoint.java&r1=1130435&r2=1130478&rev=1130478&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalSocketEndpoint.java
(original)
+++ commons/sandbox/runtime/trunk/src/main/java/org/apache/commons/runtime/net/LocalEndpoint.java
Thu Jun  2 10:40:33 2011
@@ -29,15 +29,15 @@ import org.apache.commons.runtime.Overfl
 import org.apache.commons.runtime.Status;
 
 /**
- * This class represents a local socket endpoint.
+ * This class represents a local endpoint.
  * <p>
  * Local socket represents either unix domain socket or a windows pipe,
  * depending on the operating system.
  * </p>
  */
-public class LocalSocketEndpoint extends Endpoint
+public class LocalEndpoint extends Endpoint
 {
-    private final LocalSocketDescriptor sd;
+    private final LocalDescriptor       sd;
     private SelectionKeyImpl            key;
     private boolean                     blocking = false;
 
@@ -46,16 +46,16 @@ public class LocalSocketEndpoint extends
     /**
      * Creates a new unconnected socket object.
      */
-    private LocalSocketEndpoint()
+    private LocalEndpoint()
     {
         super(EndpointType.LOCAL);
-        this.sd = new LocalSocketDescriptor();
+        this.sd = new LocalDescriptor();
     }
 
     /**
      * Creates a new socket object from socket descriptor.
      */
-    public LocalSocketEndpoint(LocalSocketDescriptor sd)
+    public LocalEndpoint(LocalDescriptor sd)
     {
         super(EndpointType.LOCAL);
         if (sd == null)

Modified: commons/sandbox/runtime/trunk/src/main/native/os/unix/usock.c
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/native/os/unix/usock.c?rev=1130478&r1=1130477&r2=1130478&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/native/os/unix/usock.c (original)
+++ commons/sandbox/runtime/trunk/src/main/native/os/unix/usock.c Thu Jun  2 10:40:33 2011
@@ -27,7 +27,7 @@
 #include <poll.h>
 #include <sys/un.h>
 
-ACR_NET_EXPORT(jint, LocalSocketDescriptor, close0)(JNI_STDARGS, jint fd)
+ACR_NET_EXPORT(jint, LocalDescriptor, close0)(JNI_STDARGS, jint fd)
 {
     if (r_close(fd) == -1)
         return ACR_GET_OS_ERROR();
@@ -35,7 +35,7 @@ ACR_NET_EXPORT(jint, LocalSocketDescript
         return 0;
 }
 
-ACR_NET_EXPORT(jint, LocalSocketDescriptor, sendz0)(JNI_STDARGS, jint fd)
+ACR_NET_EXPORT(jint, LocalDescriptor, sendz0)(JNI_STDARGS, jint fd)
 {
     if (r_write(fd, &fd, 0) == -1)
         return ACR_GET_OS_ERROR();
@@ -43,7 +43,7 @@ ACR_NET_EXPORT(jint, LocalSocketDescript
         return 0;
 }
 
-ACR_NET_EXPORT(jint, LocalSocketEndpoint, nonblock0)(JNI_STDARGS, jint fd, jboolean on)
+ACR_NET_EXPORT(jint, LocalEndpoint, nonblock0)(JNI_STDARGS, jint fd, jboolean on)
 {
     return AcrNonblock(fd, on);
 }



Mime
View raw message