Esempio n. 1
0
JNIEXPORT jlong JNICALL
Java_org_zeromq_czmq_Zsock__1_1newServer (JNIEnv *env, jclass c, jstring endpoint)
{
    char *endpoint_ = (char *) (*env)->GetStringUTFChars (env, endpoint, NULL);
    jlong new_server_ = (jlong) (intptr_t) zsock_new_server (endpoint_);
    (*env)->ReleaseStringUTFChars (env, endpoint, endpoint_);
    return new_server_;
}
Esempio n. 2
0
zchanneler_t *
zchanneler_new (const char *endpoint)
{
    zchanneler_t *self = (zchanneler_t *) zmalloc (sizeof (zchanneler_t));
    assert (self);

    self->server = zsock_new_server (endpoint);
    assert (self->server);

    self->client = zsock_new_client (endpoint);
    assert (self->client);

    return self;
}
Esempio n. 3
0
///
//  Create a SERVER socket. Default action is bind.
QZsock* QZsock::newServer (const QString &endpoint, QObject *qObjParent)
{
    return new QZsock (zsock_new_server (endpoint.toUtf8().data()), qObjParent);
}
Esempio n. 4
0
///
//  Create a SERVER socket. Default action is bind.
QmlZsock *QmlZsockAttached::constructServer (const QString &endpoint) {
    QmlZsock *qmlSelf = new QmlZsock ();
    qmlSelf->self = zsock_new_server (endpoint.toUtf8().data());
    return qmlSelf;
};