mirror of
https://github.com/2003scape/deep-c-rsc.git
synced 2024-03-22 05:49:51 -04:00
203 lines
6.2 KiB
C
203 lines
6.2 KiB
C
/* DO NOT EDIT THIS FILE - it is machine generated (JCGO_116) */
|
|
|
|
#ifdef JCGO_SEPARATED
|
|
#define JCGO_116
|
|
#include "jcgortl.h"
|
|
#include "Main.h"
|
|
#endif
|
|
|
|
#ifdef JCGO_116
|
|
|
|
#ifdef CHKALL_java_io_FileOutputStream
|
|
#include "jcgobchk.h"
|
|
#endif
|
|
|
|
JCGO_NOSEP_INLINE java_io_FileOutputStream CFASTCALL
|
|
java_io_FileOutputStream__this__L6745cZ( java_io_FileOutputStream
|
|
This, java_io_File file, jboolean append )
|
|
{
|
|
{
|
|
java_lang_SecurityManager s;
|
|
(java_io_OutputStream__this__((java_io_OutputStream)This));
|
|
s= (java_lang_System__getSecurityManager__());
|
|
if (s != jnull)
|
|
{
|
|
(java_lang_SecurityManager__checkWrite__Ls(
|
|
s, (JCGO_CALL_FINALF(file) java_io_File__getPath__(
|
|
file))));
|
|
}
|
|
{
|
|
JCGO_TRY_BLOCK
|
|
{
|
|
JCGO_FIELD_NZACCESS(This, ch)= (gnu_java_nio_FileChannelImpl__create__L6745cI(
|
|
file, (append? gnu_java_nio_FileChannelImpl__WRITE | gnu_java_nio_FileChannelImpl__APPEND :
|
|
gnu_java_nio_FileChannelImpl__WRITE)));
|
|
}
|
|
JCGO_TRY_LEAVE
|
|
JCGO_TRY_CATCHES(1)
|
|
JCGO_TRY_CATCH(OBJT_java_io_FileNotFoundException, MAXT_java_io_FileNotFoundException)
|
|
{
|
|
java_io_FileNotFoundException fnfe;
|
|
fnfe= (java_io_FileNotFoundException)JCGO_TRY_THROWABLE(0);
|
|
JCGO_THROW_EXC(fnfe);
|
|
}
|
|
JCGO_TRY_CATCH(OBJT_java_io_IOException, MAXT_java_io_IOException)
|
|
{
|
|
java_io_IOException ioe;
|
|
java_io_FileNotFoundException fnfe;
|
|
ioe= (java_io_IOException)JCGO_TRY_THROWABLE(0);
|
|
fnfe= (java_io_FileNotFoundException__new__Ls(
|
|
(JCGO_CALL_FINALF(file) java_io_File__getPath__(
|
|
file))));
|
|
(java_lang_Throwable__initCause__Lt(
|
|
(java_lang_Throwable)fnfe, (java_lang_Throwable)ioe));
|
|
JCGO_THROW_EXC(fnfe);
|
|
}
|
|
JCGO_TRY_RETHROW(1)
|
|
}
|
|
}
|
|
return This;
|
|
}
|
|
|
|
JCGO_NOSEP_INLINE java_io_FileOutputStream CFASTCALL
|
|
java_io_FileOutputStream__this__L6745c( java_io_FileOutputStream This,
|
|
java_io_File file )
|
|
{
|
|
{
|
|
(java_io_FileOutputStream__this__L6745cZ((java_io_FileOutputStream)This,
|
|
file, (jboolean)jfalse));
|
|
}
|
|
return This;
|
|
}
|
|
|
|
JCGO_NOSEP_INLINE java_io_FileOutputStream CFASTCALL
|
|
java_io_FileOutputStream__new__L6745c( java_io_File file )
|
|
{
|
|
return java_io_FileOutputStream__this__L6745c(
|
|
(java_io_FileOutputStream)jcgo_newObject((jvtable)&java_io_FileOutputStream_methods),
|
|
file);
|
|
}
|
|
|
|
JCGO_NOSEP_STATIC java_io_FileOutputStream CFASTCALL
|
|
java_io_FileOutputStream__this__L0ptnm( java_io_FileOutputStream This,
|
|
java_io_FileDescriptor fdObj )
|
|
{
|
|
{
|
|
java_lang_SecurityManager s;
|
|
(java_io_OutputStream__this__((java_io_OutputStream)This));
|
|
s= (java_lang_System__getSecurityManager__());
|
|
if (s != jnull)
|
|
{
|
|
(java_lang_SecurityManager__checkWrite__L0ptnm(
|
|
s, fdObj));
|
|
}
|
|
(void)fdObj;
|
|
JCGO_FIELD_NZACCESS(This, ch)= (gnu_java_nio_FileChannelImpl)JCGO_CAST_OBJECT0(OBJT_gnu_java_nio_FileChannelImpl,
|
|
MAXT_gnu_java_nio_FileChannelImpl, JCGO_FIELD_ACCESS(java_io_FileDescriptor,
|
|
fdObj, channel));
|
|
}
|
|
return This;
|
|
}
|
|
|
|
JCGO_NOSEP_FRWINL java_io_FileOutputStream CFASTCALL
|
|
java_io_FileOutputStream__new__L0ptnm( java_io_FileDescriptor fdObj
|
|
)
|
|
{
|
|
return java_io_FileOutputStream__this__L0ptnm(
|
|
(java_io_FileOutputStream)jcgo_newObject((jvtable)&java_io_FileOutputStream_methods),
|
|
fdObj);
|
|
}
|
|
|
|
JCGO_NOSEP_STATIC void CFASTCALL
|
|
java_io_FileOutputStream__write__BAII( java_io_FileOutputStream This,
|
|
jbyteArr buf, jint offset, jint len )
|
|
{
|
|
{
|
|
jObject jcgo_rcvrL1;
|
|
struct java_nio_ByteBufferImpl_s jcgo_stackobj1;
|
|
if (offset < 0 || len < 0 || offset + len > JCGO_ARRAY_LENGTH(buf))
|
|
{
|
|
JCGO_THROW_EXC(java_lang_ArrayIndexOutOfBoundsException__new__());
|
|
}
|
|
(jcgo_rcvrL1= (jObject)JCGO_FIELD_NZACCESS(This, ch), JCGO_CALL_FINALF((gnu_java_nio_FileChannelImpl)jcgo_rcvrL1)
|
|
gnu_java_nio_FileChannelImpl__write__L9oaia(
|
|
(gnu_java_nio_FileChannelImpl)jcgo_rcvrL1, (java_nio_ByteBuffer__wrap__BAIIX(
|
|
buf, offset, len, JCGO_STACKOBJVLT_NEW(jcgo_stackobj1, java_nio_ByteBufferImpl_methods)))));
|
|
}
|
|
}
|
|
|
|
JCGO_NOSEP_INLINE void CFASTCALL
|
|
java_io_FileOutputStream__close__( java_io_FileOutputStream This )
|
|
{
|
|
{
|
|
jObject jcgo_rcvrL1;
|
|
(jcgo_rcvrL1= (jObject)JCGO_FIELD_NZACCESS(This, ch), JCGO_CALL_FINALF((gnu_java_nio_FileChannelImpl)jcgo_rcvrL1)
|
|
java_nio_channels_spi_AbstractInterruptibleChannel__close__(
|
|
(java_nio_channels_spi_AbstractInterruptibleChannel)jcgo_rcvrL1));
|
|
}
|
|
}
|
|
|
|
JCGO_NOSEP_DATA CONST struct java_io_FileOutputStream_methods_s java_io_FileOutputStream_methods=
|
|
{
|
|
JCGO_CLASSREF_OF(java_io_FileOutputStream__class),
|
|
JCGO_GCJDESCR_ZEROINIT
|
|
OBJT_java_io_FileOutputStream,
|
|
(JCGO_OBJSIZE_T)sizeof(struct java_io_FileOutputStream_s),
|
|
NULL,
|
|
JCGO_CLINIT_INIT(0)
|
|
0,
|
|
java_lang_Object__equals__Lo,
|
|
java_lang_Object__hashCode__,
|
|
java_lang_Object__toString__,
|
|
java_lang_Object__finalize__,
|
|
java_io_FileOutputStream__write__BAII,
|
|
(void (CFASTCALL*)(java_io_OutputStream))java_lang_Object__finalize__,
|
|
java_io_FileOutputStream__close__
|
|
};
|
|
|
|
JCGO_NOSEP_DATA JCGO_NOTHR_CONST struct java_io_FileOutputStream_class_s
|
|
java_io_FileOutputStream__class JCGO_THRD_ATTRNONGC=
|
|
{
|
|
{
|
|
&java_lang_Class_methods,
|
|
JCGO_MON_INIT
|
|
JCGO_OBJREF_OF(*(java_lang_Object)&java_io_FileOutputStream_methods),
|
|
JCGO_STRREF_OF(jcgo_string1_FlOtptSt),
|
|
JCGO_CLASSREF_OF(java_io_OutputStream__class),
|
|
((jObjectArr)JCGO_OBJREF_OF(jcgo_array3_Object)),
|
|
0x1
|
|
}
|
|
};
|
|
|
|
JCGO_NOSEP_DATA CONST jcgo_arrtype94_GmCnnctn jcgo_array2_FlOtptSt=
|
|
{
|
|
(jvtable)&jbyteArr_methods,
|
|
JCGO_MON_INIT
|
|
24,
|
|
{
|
|
(jbyte)(jchar)106/*'j'*/, (jbyte)(jchar)97/*'a'*/, (jbyte)(jchar)118/*'v'*/,
|
|
(jbyte)(jchar)97/*'a'*/, (jbyte)(jchar)46/*'.'*/, (jbyte)(jchar)105/*'i'*/,
|
|
(jbyte)(jchar)111/*'o'*/, (jbyte)(jchar)46/*'.'*/, (jbyte)(jchar)70/*'F'*/,
|
|
(jbyte)(jchar)105/*'i'*/, (jbyte)(jchar)108/*'l'*/, (jbyte)(jchar)101/*'e'*/,
|
|
(jbyte)(jchar)79/*'O'*/, (jbyte)(jchar)117/*'u'*/, (jbyte)(jchar)116/*'t'*/,
|
|
(jbyte)(jchar)112/*'p'*/, (jbyte)(jchar)117/*'u'*/, (jbyte)(jchar)116/*'t'*/,
|
|
(jbyte)(jchar)83/*'S'*/, (jbyte)(jchar)116/*'t'*/, (jbyte)(jchar)114/*'r'*/,
|
|
(jbyte)(jchar)101/*'e'*/, (jbyte)(jchar)97/*'a'*/, (jbyte)(jchar)109/*'m'*/
|
|
}
|
|
};
|
|
|
|
JCGO_NOSEP_DATA JCGO_NOTHR_CONST struct java_lang_String_s jcgo_string1_FlOtptSt
|
|
JCGO_THRD_ATTRNONGC=
|
|
{
|
|
&java_lang_String_methods,
|
|
JCGO_MON_INIT
|
|
(java_lang_Object)JCGO_OBJREF_OF(jcgo_array2_FlOtptSt),
|
|
0, 24, (jint)0xdef0d599L
|
|
};
|
|
|
|
#ifdef CHKALL_java_io_FileOutputStream
|
|
#include "jcgochke.h"
|
|
#endif
|
|
|
|
#endif
|