SharedMemory.h revision 2362
1113N/A/*
2362N/A * Copyright (c) 1999, Oracle and/or its affiliates. All rights reserved.
1113N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
1113N/A *
1113N/A * This code is free software; you can redistribute it and/or modify it
1113N/A * under the terms of the GNU General Public License version 2 only, as
1113N/A * published by the Free Software Foundation. Oracle designates this
1113N/A * particular file as subject to the "Classpath" exception as provided
1113N/A * by Oracle in the LICENSE file that accompanied this code.
1113N/A *
1113N/A * This code is distributed in the hope that it will be useful, but WITHOUT
1113N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
1113N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
1113N/A * version 2 for more details (a copy is included in the LICENSE file that
1113N/A * accompanied this code).
1113N/A *
1113N/A * You should have received a copy of the GNU General Public License version
1113N/A * 2 along with this work; if not, write to the Free Software Foundation,
2362N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
2362N/A *
2362N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
1113N/A * or visit www.oracle.com if you need additional information or have any
1113N/A * questions.
1113N/A */
1113N/A#include <jni.h>
1113N/A#include "shmemBase.h"
1113N/A
1113N/A/*
1113N/A * Common declarations for native implementations of SharedMemoryTransport
1113N/A * and SharedMemoryConnection.
1113N/A */
1113N/A#define CONNECTION_TO_ID(connection) ((jlong)connection)
1113N/A#define ID_TO_CONNECTION(id) ((SharedMemoryConnection *)id)
1113N/A#define TRANSPORT_TO_ID(transport) ((jlong)transport)
1113N/A#define ID_TO_TRANSPORT(id) ((SharedMemoryTransport *)id)
1113N/A
1113N/A/*
1113N/A * Defined in SharedMemoryTransport.c
1113N/A */
1113N/Avoid throwException(JNIEnv *env, char *exceptionClassName, char *message);
1113N/Avoid throwShmemException(JNIEnv *env, char *message, jint errorCode);
1113N/A