@Draft
    public Object[] recvBinaryPicture(Socket socket, final String picture)
    {
        if (!BINARY_FORMAT.matcher(picture).matches()) {
            throw new ZMQException(picture + " is not in expected binary format " + BINARY_FORMAT.pattern(),
                    ZError.EPROTO);
        }
        ZFrame frame = ZFrame.recvFrame(socket);
        if (frame == null) {
            return null;
        }
        //  Get the data frame
        ZNeedle needle = new ZNeedle(frame);

        Object[] results = new Object[picture.length()];
        for (int index = 0; index < picture.length(); index++) {
            char pattern = picture.charAt(index);
            switch (pattern) {
            case '1': {
                results[index] = needle.getNumber1();
                break;
            }
            case '2': {
                results[index] = needle.getNumber2();
                break;
            }
            case '4': {
                results[index] = needle.getNumber4();
                break;
            }
            case '8': {
                results[index] = needle.getNumber8();
                break;
            }
            case 's': {
                results[index] = needle.getString();
                break;
            }
            case 'S': {
                results[index] = needle.getLongString();
                break;
            }
            case 'b':
            case 'c': {
                int size = needle.getNumber4();
                results[index] = needle.getBlock(size);
                break;
            }
            case 'f': {
                // Get next frame off socket
                results[index] = ZFrame.recvFrame(socket);
                break;
            }
            case 'm': {
                // Get zero or more remaining frames
                results[index] = ZMsg.recvMsg(socket);
                break;
            }
            default:
                assert (false) : "invalid picture element '" + pattern + "'";
            }
        }
        return results;
    }
@ Draft public Object [ ] recvBinaryPicture ( Socket socket , final String picture ) { if ( ! BINARY_FORMAT . matcher ( picture ) . matches ( ) ) { throw new ZMQException ( picture + " is not in expected binary format " + BINARY_FORMAT . pattern ( ) , ZError . EPROTO ) ; } ZFrame frame = ZFrame . recvFrame ( socket ) ; if ( frame == null ) { return null ; } ZNeedle needle = new ZNeedle ( frame ) ; Object [ ] results = new Object [ picture . length ( ) ] ; for ( int index = 0 ; index < picture . length ( ) ; index ++ ) { char pattern = picture . charAt ( index ) ; switch ( pattern ) { case '1' : { results [ index ] = needle . getNumber1 ( ) ; break ; } case '2' : { results [ index ] = needle . getNumber2 ( ) ; break ; } case '4' : { results [ index ] = needle . getNumber4 ( ) ; break ; } case '8' : { results [ index ] = needle . getNumber8 ( ) ; break ; } case 's' : { results [ index ] = needle . getString ( ) ; break ; } case 'S' : { results [ index ] = needle . getLongString ( ) ; break ; } case 'b' : case 'c' : { int size = needle . getNumber4 ( ) ; results [ index ] = needle . getBlock ( size ) ; break ; } case 'f' : { results [ index ] = ZFrame . recvFrame ( socket ) ; break ; } case 'm' : { results [ index ] = ZMsg . recvMsg ( socket ) ; break ; } default : assert ( false ) : "invalid picture element '" + pattern + "'" ; } } return results ; }
Receive a binary encoded 'picture' message from the socket (or actor).
This method is similar to {@link org.zeromq.ZMQ.Socket#recv()}, except the arguments are encoded
in a binary format that is compatible with zproto, and is designed to
reduce memory allocations.

@param picture The picture argument is a string that defines
the type of each argument. See {@link #sendBinaryPicture(Socket, String, Object...)}
for the supported argument types.
@return the picture elements as object array