directbytebufferimpl.c

来自「kaffe Java 解释器语言,源码,Java的子集系统,开放源代码」· C语言 代码 · 共 39 行

C
39
字号
/* * DirectByteBufferImpl.c * * Copyright (c) 2003 Kaffe's team. * * See the file "license.terms" for information on usage and redistribution * of this file. */ #include "config.h"#include "config-std.h"#include "kaffe/jmalloc.h"#include "java_nio_DirectByteBufferImpl.h"struct Hgnu_classpath_RawData*java_nio_DirectByteBufferImpl_allocateImpl(jint bytes){  return (struct Hgnu_classpath_RawData*)jmalloc(bytes);}voidjava_nio_DirectByteBufferImpl_freeImpl(struct Hgnu_classpath_RawData* data){  jfree(data);}jbytejava_nio_DirectByteBufferImpl_getImpl(struct Hjava_nio_DirectByteBufferImpl* this, jint index){  return ((jbyte *)unhand(this)->address)[index];}voidjava_nio_DirectByteBufferImpl_putImpl(struct Hjava_nio_DirectByteBufferImpl* this, jint index,				      jbyte b){  ((jbyte *)unhand(this)->address)[index] = b;}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?