Class CudaSocket

  • All Implemented Interfaces:
    InputSocket<java.lang.Boolean>, Socket<java.lang.Boolean>

    public class CudaSocket
    extends InputSocketImpl<java.lang.Boolean>
    A type of input socket that lets an operation know that it should prefer to use a CUDA-accelerated code path. If no compatible CUDA runtime is available, sockets of this type will always have a value of false and cannot be changed.
    • Method Detail

      • getValue

        public java.util.Optional<java.lang.Boolean> getValue()
        Specified by:
        getValue in interface Socket<java.lang.Boolean>
        Overrides:
        getValue in class SocketImpl<java.lang.Boolean>
        Returns:
        The value currently stored in this socket.
      • setValue

        public void setValue​(@Nullable
                             java.lang.Boolean value)
        Description copied from interface: Socket
        Set the value of the socket, and fire off a SocketChangedEvent.
        Parameters:
        value - The value to store in this socket. Nullable.
      • setValueOptional

        public void setValueOptional​(java.util.Optional<? extends java.lang.Boolean> optionalValue)
        Description copied from interface: Socket
        Set the value of the socket using an Optional, and fire off a SocketChangedEvent.
        Specified by:
        setValueOptional in interface Socket<java.lang.Boolean>
        Overrides:
        setValueOptional in class SocketImpl<java.lang.Boolean>
        Parameters:
        optionalValue - The optional value to assign this socket to.
      • isCudaAvailable

        public boolean isCudaAvailable()